/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package midlet;

import connection.*;
import java.util.Vector;
import javax.microedition.midlet.*;
import javax.microedition.lcdui.*;
import org.netbeans.microedition.lcdui.SplashScreen;

/**
 * @author psychok7
 */
public class MobileUCMIDlet extends MIDlet implements CommandListener, ItemCommandListener {

    private Display display;
    private boolean midletPaused = false;
    private Connection conn;
    private int selectedDay = 0;
    private String[] weekDays = {"Segunda feira", "Terça feria", "Quarta feria", "Quinta feria", "Sexta feria"};
    private int totalCadeiras = -1;
    private int cadeiraActual = -1;
    private int totalMaterials = -1;
    private int currentMaterial = -1;
    public boolean newAlert = false;
    private boolean logged = false;
    ReceiveSMS receiveSMS;
//<editor-fold defaultstate="collapsed" desc=" Generated Fields ">//GEN-BEGIN:|fields|0|
    private java.util.Hashtable __previousDisplayables = new java.util.Hashtable();
    private Command exitCommand;
    private Command okLogin;
    private Command okSplash;
    private Command okAlert;
    private Command goToSchedule;
    private Command goToAlerts;
    private Command goToClasses;
    private Command goToMainMenu;
    private Command goToMessages;
    private Command backSendSMS;
    private Command backClasses;
    private Command backAlerts;
    private Command backClasseX;
    private Command backInformation;
    private Command backSupportMaterial;
    private Command goToClasseX;
    private Command goToInfo;
    private Command goToSupportMaterial;
    private Command goToDay;
    private Command backDay;
    private Command gotoMaterials;
    private Command goToDocument;
    private Command backDocument;
    private Command okSendSMS;
    private Command screenCommand;
    private Command goToSupportMaterials;
    private Command screenCommand1;
    private Command goToSendSMS;
    private Command goToInbox;
    private Command goToSendSMS1;
    private Command goToInbox1;
    private Command backCommand;
    private Command backMessages;
    private Command backInbox;
    private Command goToInbox2;
    private Form login;
    private TextField loginPass;
    private TextField loginName;
    private Alert welcomeScreen;
    private SplashScreen splashScreen;
    private Form mainMenu;
    private ImageItem imageItem;
    private ImageItem imageItem1;
    private ImageItem imageItem2;
    private ImageItem imageItem3;
    private Spacer spacer1;
    private Spacer spacer2;
    private Form schedule;
    private ChoiceGroup choiceGroup;
    private ImageItem imageItem9;
    private ImageItem imageItem8;
    private Spacer spacer4;
    private Form sendSMS;
    private TextField smsReceiver;
    private Spacer spacer;
    private TextField smsText;
    private Form alerts;
    private StringItem alertText;
    private Form classes;
    private ChoiceGroup coursesList;
    private ImageItem imageItem10;
    private ImageItem imageItem11;
    private Spacer spacer5;
    private Form classeX;
    private ImageItem imageItem4;
    private ImageItem imageItem5;
    private ImageItem imageItem6;
    private ImageItem imageItem7;
    private Spacer spacer3;
    private Form supportMaterial;
    private ChoiceGroup supportMaterials;
    private Spacer spacer6;
    private ImageItem imageItem12;
    private ImageItem imageItem13;
    private Form information;
    private StringItem courseInfo;
    private ImageItem imageItem14;
    private ImageItem imageItem15;
    private Spacer spacer7;
    private Form day;
    private StringItem daySchedule;
    private ImageItem imageItem17;
    private ImageItem imageItem16;
    private Spacer spacer8;
    private Form document;
    private StringItem currentDocument;
    private ImageItem imageItem18;
    private Spacer spacer9;
    private ImageItem imageItem19;
    private Form messages;
    private ImageItem imageItem20;
    private Spacer spacer10;
    private ImageItem imageItem21;
    private ImageItem inbox;
    private ImageItem imageItem22;
    private Form inboxScreen;
    private Spacer spacer11;
    private ImageItem imageItem24;
    private ImageItem imageItem23;
    private StringItem inboxList;
    private Image cadeiras;
    private Image horario;
    private Image alertaOff;
    private Image mensagemOff;
    private Image fctuc;
    private Image materialApoio;
    private Image notas;
    private Image mensagemOn;
    private Image alertaOn;
    private Font dayFont;
    private Image sendSMSImg;
    private Image inboxSMSImg;
//</editor-fold>//GEN-END:|fields|0|

    /**
     * The MobileUCMIDlet constructor.
     */
    public MobileUCMIDlet() {
        display = Display.getDisplay(this);
        receiveSMS = new ReceiveSMS();
    }

//<editor-fold defaultstate="collapsed" desc=" Generated Methods ">//GEN-BEGIN:|methods|0|
    /**
     * Switches a display to previous displayable of the current displayable.
     * The <code>display</code> instance is obtain from the <code>getDisplay</code> method.
     */
    private void switchToPreviousDisplayable() {
        Displayable __currentDisplayable = getDisplay().getCurrent();
        if (__currentDisplayable != null) {
            Displayable __nextDisplayable = (Displayable) __previousDisplayables.get(__currentDisplayable);
            if (__nextDisplayable != null) {
                switchDisplayable(null, __nextDisplayable);
            }
        }
    }
//</editor-fold>//GEN-END:|methods|0|
//<editor-fold defaultstate="collapsed" desc=" Generated Method: initialize ">//GEN-BEGIN:|0-initialize|0|0-preInitialize

    /**
     * Initializes the application.
     * It is called only once when the MIDlet is started. The method is called before the <code>startMIDlet</code> method.
     */
    private void initialize() {//GEN-END:|0-initialize|0|0-preInitialize
        // write pre-initialize user code here
        conn = new Connection("", this);
//GEN-LINE:|0-initialize|1|0-postInitialize
        // write post-initialize user code here
    }//GEN-BEGIN:|0-initialize|2|
//</editor-fold>//GEN-END:|0-initialize|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Method: startMIDlet ">//GEN-BEGIN:|3-startMIDlet|0|3-preAction
    /**
     * Performs an action assigned to the Mobile Device - MIDlet Started point.
     */
    public void startMIDlet() {//GEN-END:|3-startMIDlet|0|3-preAction
        // write pre-action user code here

        switchDisplayable(null, getSplashScreen());//GEN-LINE:|3-startMIDlet|1|3-postAction
        // write post-action user code here
    }//GEN-BEGIN:|3-startMIDlet|2|
//</editor-fold>//GEN-END:|3-startMIDlet|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Method: resumeMIDlet ">//GEN-BEGIN:|4-resumeMIDlet|0|4-preAction
    /**
     * Performs an action assigned to the Mobile Device - MIDlet Resumed point.
     */
    public void resumeMIDlet() {//GEN-END:|4-resumeMIDlet|0|4-preAction
        // write pre-action user code here
//GEN-LINE:|4-resumeMIDlet|1|4-postAction
        // write post-action user code here
    }//GEN-BEGIN:|4-resumeMIDlet|2|
//</editor-fold>//GEN-END:|4-resumeMIDlet|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Method: switchDisplayable ">//GEN-BEGIN:|5-switchDisplayable|0|5-preSwitch
    /**
     * Switches a current displayable in a display. The <code>display</code> instance is taken from <code>getDisplay</code> method. This method is used by all actions in the design for switching displayable.
     * @param alert the Alert which is temporarily set to the display; if <code>null</code>, then <code>nextDisplayable</code> is set immediately
     * @param nextDisplayable the Displayable to be set
     */
    public void switchDisplayable(Alert alert, Displayable nextDisplayable) {//GEN-END:|5-switchDisplayable|0|5-preSwitch
        // write pre-switch user code here
        Display display = getDisplay();//GEN-BEGIN:|5-switchDisplayable|1|5-postSwitch
        Displayable __currentDisplayable = display.getCurrent();
        if (__currentDisplayable != null && nextDisplayable != null) {
            __previousDisplayables.put(nextDisplayable, __currentDisplayable);
        }
        if (alert == null) {
            display.setCurrent(nextDisplayable);
        } else {
            display.setCurrent(alert, nextDisplayable);
        }//GEN-END:|5-switchDisplayable|1|5-postSwitch
        // write post-switch user code here
    }//GEN-BEGIN:|5-switchDisplayable|2|
//</editor-fold>//GEN-END:|5-switchDisplayable|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Method: commandAction for Displayables ">//GEN-BEGIN:|7-commandAction|0|7-preCommandAction
    /**
     * Called by a system to indicated that a command has been invoked on a particular displayable.
     * @param command the Command that was invoked
     * @param displayable the Displayable where the command was invoked
     */
    public void commandAction(Command command, Displayable displayable) {//GEN-END:|7-commandAction|0|7-preCommandAction
        // write pre-action user code here
        if (displayable == alerts) {//GEN-BEGIN:|7-commandAction|1|75-preAction
            if (command == backAlerts) {//GEN-END:|7-commandAction|1|75-preAction
                alerts.deleteAll();
                alertText = null;
                clearIcons();
                alerts = null;
                newAlert= false;
                switchToPreviousDisplayable();//GEN-LINE:|7-commandAction|2|75-postAction
                
            }//GEN-BEGIN:|7-commandAction|3|89-preAction
        } else if (displayable == classeX) {
            if (command == backClasseX) {//GEN-END:|7-commandAction|3|89-preAction

                switchDisplayable(null, getClasses());//GEN-LINE:|7-commandAction|4|89-postAction
                classeX.deleteAll();
                clearIcons();
                classeX = null;
            }//GEN-BEGIN:|7-commandAction|5|73-preAction
        } else if (displayable == classes) {
            if (command == backClasses) {//GEN-END:|7-commandAction|5|73-preAction
                clearIcons();
                switchDisplayable(null, getMainMenu());//GEN-LINE:|7-commandAction|6|73-postAction
                // write post-action user code here
            } else if (command == goToClasseX) {//GEN-LINE:|7-commandAction|7|97-preAction

                this.cadeiraActual = coursesList.getSelectedIndex();
                //this.totalMaterials= vai buscar;
                //System.out.println("\t\tCadeira:" + coursesList.getString(this.cadeiraActual));
                clearIcons();

                switchDisplayable(null, getClasseX());//GEN-LINE:|7-commandAction|8|97-postAction
                // write post-action user code here
            }//GEN-BEGIN:|7-commandAction|9|122-preAction
        } else if (displayable == day) {
            if (command == backDay) {//GEN-END:|7-commandAction|9|122-preAction
                day.deleteAll();
                daySchedule = null;
                clearIcons();
                day = null;

                switchToPreviousDisplayable();//GEN-LINE:|7-commandAction|10|122-postAction


            }//GEN-BEGIN:|7-commandAction|11|134-preAction
        } else if (displayable == document) {
            if (command == backDocument) {//GEN-END:|7-commandAction|11|134-preAction

                switchToPreviousDisplayable();//GEN-LINE:|7-commandAction|12|134-postAction
                document.deleteAll();
                currentDocument = null;
                clearIcons();
                document = null;
            }//GEN-BEGIN:|7-commandAction|13|252-preAction
        } else if (displayable == inboxScreen) {
            if (command == backInbox) {//GEN-END:|7-commandAction|13|252-preAction

                switchToPreviousDisplayable();//GEN-LINE:|7-commandAction|14|252-postAction
                inboxScreen.deleteAll();
                inboxList = null;
                clearIcons();
                inboxScreen = null;
            }//GEN-BEGIN:|7-commandAction|15|103-preAction
        } else if (displayable == information) {
            if (command == backInformation) {//GEN-END:|7-commandAction|15|103-preAction

                switchToPreviousDisplayable();//GEN-LINE:|7-commandAction|16|103-postAction
                information.deleteAll();
                courseInfo = null;
                clearIcons();
                information = null;
            }//GEN-BEGIN:|7-commandAction|17|19-preAction
        } else if (displayable == login) {
            if (command == exitCommand) {//GEN-END:|7-commandAction|17|19-preAction
                // write pre-action user code here
                exitMIDlet();//GEN-LINE:|7-commandAction|18|19-postAction
                // write post-action user code here
            } else if (command == okLogin) {//GEN-LINE:|7-commandAction|19|26-preAction
                // write pre-action user code here

                try {
                    new Thread(new Runnable() {

                        public void run() {
                            try {
                                if (conn.checkUserCredentials(loginName.getString(), loginPass.getString())) {
                                    switchDisplayable(null, getWelcomeScreen());//GEN-LINE:|7-commandAction|20|26-postAction
                                    // write post-action user code here
                                    logged = true;
                                    welcomeScreen.setString("Bem vindo  " + loginName.getString() + " !");
                                    //stringItem.setText("Greetings " + loginName.getString());
                                } else {
                                    logged = false;
                                    switchDisplayable(getWelcomeScreen(), getLogin());
                                    welcomeScreen.setString("Dados errados!");
                                }

                            } catch (Exception e) {
                                System.out.println(e.toString());
                            }
                        }
                    }).start();
                } catch (Exception e) {
                    System.out.println(e.toString());
                }
            }//GEN-BEGIN:|7-commandAction|21|256-preAction
        } else if (displayable == messages) {
            if (command == backCommand) {//GEN-END:|7-commandAction|21|256-preAction
                clearIcons();
                switchDisplayable(null, getMainMenu());//GEN-LINE:|7-commandAction|22|256-postAction
                // write post-action user code here
            }//GEN-BEGIN:|7-commandAction|23|117-preAction
        } else if (displayable == schedule) {
            if (command == goToDay) {//GEN-END:|7-commandAction|23|117-preAction
                // write pre-action user code here

                this.selectedDay = choiceGroup.getSelectedIndex();
                //System.out.println("\t\tDia:" + choiceGroup.getString(this.selectedDay));
                clearIcons();
                switchDisplayable(null, getDay());//GEN-LINE:|7-commandAction|24|117-postAction

// write post-action user code here
            } else if (command == goToMainMenu) {//GEN-LINE:|7-commandAction|25|70-preAction
                mainMenu.deleteAll();
                mainMenu = null;
                clearIcons();
                switchDisplayable(null, getMainMenu());//GEN-LINE:|7-commandAction|26|70-postAction
                // write post-action user code here
            }//GEN-BEGIN:|7-commandAction|27|77-preAction
        } else if (displayable == sendSMS) {
            if (command == backSendSMS) {//GEN-END:|7-commandAction|27|77-preAction
                clearIcons();
                switchToPreviousDisplayable();//GEN-LINE:|7-commandAction|28|77-postAction
                // write post-action user code here
            } else if (command == okSendSMS) {//GEN-LINE:|7-commandAction|29|156-preAction
                // write pre-action user code here
//GEN-LINE:|7-commandAction|30|156-postAction
                String destinatario = smsReceiver.getString();
                String texto = smsText.getString();

                SendSMS sendSMS = new SendSMS(destinatario, texto);
            }//GEN-BEGIN:|7-commandAction|31|33-preAction
        } else if (displayable == splashScreen) {
            if (command == SplashScreen.DISMISS_COMMAND) {//GEN-END:|7-commandAction|31|33-preAction
                // write pre-action user code here
//GEN-LINE:|7-commandAction|32|33-postAction
                // write post-action user code here
            } else if (command == okSplash) {//GEN-LINE:|7-commandAction|33|35-preAction
                // write pre-action user code here
                switchDisplayable(null, getLogin());//GEN-LINE:|7-commandAction|34|35-postAction
                // write post-action user code here
            }//GEN-BEGIN:|7-commandAction|35|100-preAction
        } else if (displayable == supportMaterial) {
            if (command == backSupportMaterial) {//GEN-END:|7-commandAction|35|100-preAction
                clearIcons();
                switchDisplayable(null, getClasseX());//GEN-LINE:|7-commandAction|36|100-postAction
                // write post-action user code here
            } else if (command == goToDocument) {//GEN-LINE:|7-commandAction|37|130-preAction
                // System.out.println("\t\tBota la sacar esse negocio!");

                this.currentMaterial = supportMaterials.getSelectedIndex();
                clearIcons();
                //  System.out.println("\t\tMaterial actual: " + this.currentMaterial);

                switchDisplayable(null, getDocument());//GEN-LINE:|7-commandAction|38|130-postAction

            }//GEN-BEGIN:|7-commandAction|39|47-preAction
        } else if (displayable == welcomeScreen) {
            if (command == okAlert) {//GEN-END:|7-commandAction|39|47-preAction
                // write pre-action user code here
                verificaLogin();//GEN-LINE:|7-commandAction|40|47-postAction
                // write post-action user code here
            }//GEN-BEGIN:|7-commandAction|41|7-postCommandAction
        }//GEN-END:|7-commandAction|41|7-postCommandAction
        // write post-action user code here
    }//GEN-BEGIN:|7-commandAction|42|
//</editor-fold>//GEN-END:|7-commandAction|42|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: exitCommand ">//GEN-BEGIN:|18-getter|0|18-preInit
    /**
     * Returns an initiliazed instance of exitCommand component.
     * @return the initialized component instance
     */
    public Command getExitCommand() {
        if (exitCommand == null) {//GEN-END:|18-getter|0|18-preInit
            // write pre-init user code here
            exitCommand = new Command("Exit", Command.EXIT, 0);//GEN-LINE:|18-getter|1|18-postInit
            // write post-init user code here
        }//GEN-BEGIN:|18-getter|2|
        return exitCommand;
    }
//</editor-fold>//GEN-END:|18-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: login ">//GEN-BEGIN:|14-getter|0|14-preInit
    /**
     * Returns an initiliazed instance of login component.
     * @return the initialized component instance
     */
    public Form getLogin() {
        if (login == null) {//GEN-END:|14-getter|0|14-preInit
            // write pre-init user code here
            login = new Form("Welcome", new Item[]{getLoginName(), getLoginPass()});//GEN-BEGIN:|14-getter|1|14-postInit
            login.addCommand(getExitCommand());
            login.addCommand(getOkLogin());
            login.setCommandListener(this);//GEN-END:|14-getter|1|14-postInit
            // write post-init user code here
        }//GEN-BEGIN:|14-getter|2|
        return login;
    }
//</editor-fold>//GEN-END:|14-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: loginName ">//GEN-BEGIN:|22-getter|0|22-preInit
    /**
     * Returns an initiliazed instance of loginName component.
     * @return the initialized component instance
     */
    public TextField getLoginName() {
        if (loginName == null) {//GEN-END:|22-getter|0|22-preInit
            // write pre-init user code here
            loginName = new TextField("Name:", null, 32, TextField.ANY);//GEN-BEGIN:|22-getter|1|22-postInit
            loginName.setPreferredSize(-1, -1);
            loginName.setLayout(ImageItem.LAYOUT_DEFAULT);//GEN-END:|22-getter|1|22-postInit
            // write post-init user code here
        }//GEN-BEGIN:|22-getter|2|
        return loginName;
    }
//</editor-fold>//GEN-END:|22-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: okLogin ">//GEN-BEGIN:|25-getter|0|25-preInit
    /**
     * Returns an initiliazed instance of okLogin component.
     * @return the initialized component instance
     */
    public Command getOkLogin() {
        if (okLogin == null) {//GEN-END:|25-getter|0|25-preInit
            // write pre-init user code here
            okLogin = new Command("Ok", Command.OK, 0);//GEN-LINE:|25-getter|1|25-postInit
            // write post-init user code here
        }//GEN-BEGIN:|25-getter|2|
        return okLogin;
    }
//</editor-fold>//GEN-END:|25-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: welcomeScreen ">//GEN-BEGIN:|24-getter|0|24-preInit
    /**
     * Returns an initiliazed instance of welcomeScreen component.
     * @return the initialized component instance
     */
    public Alert getWelcomeScreen() {
        if (welcomeScreen == null) {//GEN-END:|24-getter|0|24-preInit
            // write pre-init user code here
            welcomeScreen = new Alert("alert");//GEN-BEGIN:|24-getter|1|24-postInit
            welcomeScreen.addCommand(getOkAlert());
            welcomeScreen.setCommandListener(this);
            welcomeScreen.setTimeout(1000);//GEN-END:|24-getter|1|24-postInit

        }//GEN-BEGIN:|24-getter|2|
        return welcomeScreen;
    }
//</editor-fold>//GEN-END:|24-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: loginPass ">//GEN-BEGIN:|23-getter|0|23-preInit
    /**
     * Returns an initiliazed instance of loginPass component.
     * @return the initialized component instance
     */
    public TextField getLoginPass() {
        if (loginPass == null) {//GEN-END:|23-getter|0|23-preInit
            // write pre-init user code here
            loginPass = new TextField("Password:", null, 32, TextField.ANY | TextField.PASSWORD);//GEN-LINE:|23-getter|1|23-postInit
            // write post-init user code here
        }//GEN-BEGIN:|23-getter|2|
        return loginPass;
    }
//</editor-fold>//GEN-END:|23-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: okSplash ">//GEN-BEGIN:|34-getter|0|34-preInit
    /**
     * Returns an initiliazed instance of okSplash component.
     * @return the initialized component instance
     */
    public Command getOkSplash() {
        if (okSplash == null) {//GEN-END:|34-getter|0|34-preInit
            // write pre-init user code here
            okSplash = new Command("Ok", Command.OK, 0);//GEN-LINE:|34-getter|1|34-postInit
            // write post-init user code here
        }//GEN-BEGIN:|34-getter|2|
        return okSplash;
    }
//</editor-fold>//GEN-END:|34-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: splashScreen ">//GEN-BEGIN:|31-getter|0|31-preInit
    /**
     * Returns an initiliazed instance of splashScreen component.
     * @return the initialized component instance
     */
    public SplashScreen getSplashScreen() {
        if (splashScreen == null) {//GEN-END:|31-getter|0|31-preInit
            // write pre-init user code here
            splashScreen = new SplashScreen(getDisplay());//GEN-BEGIN:|31-getter|1|31-postInit
            splashScreen.setTitle("");
            splashScreen.addCommand(getOkSplash());
            splashScreen.setCommandListener(this);
            splashScreen.setFullScreenMode(true);
            splashScreen.setImage(getFctuc());//GEN-END:|31-getter|1|31-postInit
            try {
                Thread.sleep(1);


                switchDisplayable(null, getLogin());

            } catch (Exception ex) {
            }

// write post-init user code here
        }//GEN-BEGIN:|31-getter|2|
        return splashScreen;
    }
//</editor-fold>//GEN-END:|31-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: cadeiras ">//GEN-BEGIN:|40-getter|0|40-preInit
    /**
     * Returns an initiliazed instance of cadeiras component.
     * @return the initialized component instance
     */
    public Image getCadeiras() {
        if (cadeiras == null) {//GEN-END:|40-getter|0|40-preInit
            // write pre-init user code here
            try {//GEN-BEGIN:|40-getter|1|40-@java.io.IOException
                cadeiras = Image.createImage("/images/cadeiras.png");
            } catch (java.io.IOException e) {//GEN-END:|40-getter|1|40-@java.io.IOException
                e.printStackTrace();
            }//GEN-LINE:|40-getter|2|40-postInit
            // write post-init user code here
        }//GEN-BEGIN:|40-getter|3|
        return cadeiras;
    }
//</editor-fold>//GEN-END:|40-getter|3|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: horario ">//GEN-BEGIN:|41-getter|0|41-preInit
    /**
     * Returns an initiliazed instance of horario component.
     * @return the initialized component instance
     */
    public Image getHorario() {
        if (horario == null) {//GEN-END:|41-getter|0|41-preInit
            // write pre-init user code here
            try {//GEN-BEGIN:|41-getter|1|41-@java.io.IOException
                horario = Image.createImage("/images/horario.png");
            } catch (java.io.IOException e) {//GEN-END:|41-getter|1|41-@java.io.IOException
                e.printStackTrace();
            }//GEN-LINE:|41-getter|2|41-postInit
            // write post-init user code here
        }//GEN-BEGIN:|41-getter|3|
        return horario;
    }
//</editor-fold>//GEN-END:|41-getter|3|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: mainMenu ">//GEN-BEGIN:|42-getter|0|42-preInit
    /**
     * Returns an initiliazed instance of mainMenu component.
     * @return the initialized component instance
     */
    public Form getMainMenu() {
        if (mainMenu == null) {//GEN-END:|42-getter|0|42-preInit



            mainMenu = new Form("Inforestudante", new Item[]{getImageItem(), getImageItem1(), getSpacer1(), getImageItem2(), getSpacer2(), getImageItem3()});//GEN-LINE:|42-getter|1|42-postInit
            // write post-init user code here
        }//GEN-BEGIN:|42-getter|2|
        return mainMenu;
    }
//</editor-fold>//GEN-END:|42-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem ">//GEN-BEGIN:|43-getter|0|43-preInit
    /**
     * Returns an initiliazed instance of imageItem component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem() {
        if (imageItem == null) {//GEN-END:|43-getter|0|43-preInit
            System.out.println("\t\tNewAlert: " + this.newAlert);
            imageItem = new ImageItem("", this.newAlert ? getAlertaOn() : getAlertaOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER, "<Missing Image>", Item.HYPERLINK);//GEN-BEGIN:|43-getter|1|43-postInit
            imageItem.addCommand(getGoToAlerts());
            imageItem.setItemCommandListener(this);
            imageItem.setDefaultCommand(getGoToAlerts());//GEN-END:|43-getter|1|43-postInit
            // write post-init user code here
        }//GEN-BEGIN:|43-getter|2|
        return imageItem;
    }
//</editor-fold>//GEN-END:|43-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: alertaOff ">//GEN-BEGIN:|44-getter|0|44-preInit
    /**
     * Returns an initiliazed instance of alertaOff component.
     * @return the initialized component instance
     */
    public Image getAlertaOff() {
        if (alertaOff == null) {//GEN-END:|44-getter|0|44-preInit
            // write pre-init user code here
            try {//GEN-BEGIN:|44-getter|1|44-@java.io.IOException
                alertaOff = Image.createImage("/images/alerta_off.png");
            } catch (java.io.IOException e) {//GEN-END:|44-getter|1|44-@java.io.IOException
                e.printStackTrace();
            }//GEN-LINE:|44-getter|2|44-postInit
            // write post-init user code here
        }//GEN-BEGIN:|44-getter|3|
        return alertaOff;
    }
//</editor-fold>//GEN-END:|44-getter|3|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: okAlert ">//GEN-BEGIN:|46-getter|0|46-preInit
    /**
     * Returns an initiliazed instance of okAlert component.
     * @return the initialized component instance
     */
    public Command getOkAlert() {
        if (okAlert == null) {//GEN-END:|46-getter|0|46-preInit
            // write pre-init user code here
            okAlert = new Command("Ok", Command.OK, 0);//GEN-LINE:|46-getter|1|46-postInit
            // write post-init user code here
        }//GEN-BEGIN:|46-getter|2|
        return okAlert;
    }
//</editor-fold>//GEN-END:|46-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem1 ">//GEN-BEGIN:|49-getter|0|49-preInit
    /**
     * Returns an initiliazed instance of imageItem1 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem1() {
        if (imageItem1 == null) {//GEN-END:|49-getter|0|49-preInit
            // write pre-init user code here
            imageItem1 = new ImageItem("", receiveSMS.isNewAlert() ? getMensagemOn() : getMensagemOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_VCENTER, "<Missing Image>", Item.PLAIN);//GEN-BEGIN:|49-getter|1|49-postInit
            imageItem1.addCommand(getGoToMessages());
            imageItem1.setItemCommandListener(this);//GEN-END:|49-getter|1|49-postInit
            // write post-init user code here
        }//GEN-BEGIN:|49-getter|2|
        return imageItem1;
    }
//</editor-fold>//GEN-END:|49-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: mensagemOff ">//GEN-BEGIN:|50-getter|0|50-preInit
    /**
     * Returns an initiliazed instance of mensagemOff component.
     * @return the initialized component instance
     */
    public Image getMensagemOff() {
        if (mensagemOff == null) {//GEN-END:|50-getter|0|50-preInit
            // write pre-init user code here
            try {//GEN-BEGIN:|50-getter|1|50-@java.io.IOException
                mensagemOff = Image.createImage("/images/mensagem_lida.png");
            } catch (java.io.IOException e) {//GEN-END:|50-getter|1|50-@java.io.IOException
                e.printStackTrace();
            }//GEN-LINE:|50-getter|2|50-postInit
            // write post-init user code here
        }//GEN-BEGIN:|50-getter|3|
        return mensagemOff;
    }
//</editor-fold>//GEN-END:|50-getter|3|

//<editor-fold defaultstate="collapsed" desc=" Generated Method: commandAction for Items ">//GEN-BEGIN:|17-itemCommandAction|0|17-preItemCommandAction
    /**
     * Called by a system to indicated that a command has been invoked on a particular item.
     * @param command the Command that was invoked
     * @param displayable the Item where the command was invoked
     */
    public void commandAction(Command command, Item item) {//GEN-END:|17-itemCommandAction|0|17-preItemCommandAction
        // write pre-action user code here
        if (item == imageItem) {//GEN-BEGIN:|17-itemCommandAction|1|64-preAction
            if (command == goToAlerts) {//GEN-END:|17-itemCommandAction|1|64-preAction
                // write pre-action user code here
                switchDisplayable(null, getAlerts());//GEN-LINE:|17-itemCommandAction|2|64-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|3|67-preAction
        } else if (item == imageItem1) {
            if (command == goToMessages) {//GEN-END:|17-itemCommandAction|3|67-preAction
                // write pre-action user code here
                switchDisplayable(null, getMessages());//GEN-LINE:|17-itemCommandAction|4|67-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|5|181-preAction
        } else if (item == imageItem11) {
            if (command == goToMessages) {//GEN-END:|17-itemCommandAction|5|181-preAction
                // write pre-action user code here
//GEN-LINE:|17-itemCommandAction|6|181-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|7|186-preAction
        } else if (item == imageItem12) {
            if (command == goToAlerts) {//GEN-END:|17-itemCommandAction|7|186-preAction
                // write pre-action user code here
                switchDisplayable(null, getAlerts());//GEN-LINE:|17-itemCommandAction|8|186-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|9|185-preAction
        } else if (item == imageItem13) {
            if (command == goToMessages) {//GEN-END:|17-itemCommandAction|9|185-preAction
                // write pre-action user code here
                switchDisplayable(null, getMessages());//GEN-LINE:|17-itemCommandAction|10|185-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|11|191-preAction
        } else if (item == imageItem14) {
            if (command == goToAlerts) {//GEN-END:|17-itemCommandAction|11|191-preAction
                // write pre-action user code here
                switchDisplayable(null, getAlerts());//GEN-LINE:|17-itemCommandAction|12|191-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|13|190-preAction
        } else if (item == imageItem15) {
            if (command == goToMessages) {//GEN-END:|17-itemCommandAction|13|190-preAction
                // write pre-action user code here
                switchDisplayable(null, getMessages());//GEN-LINE:|17-itemCommandAction|14|190-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|15|196-preAction
        } else if (item == imageItem16) {
            if (command == goToAlerts) {//GEN-END:|17-itemCommandAction|15|196-preAction
                // write pre-action user code here
                switchDisplayable(null, getAlerts());//GEN-LINE:|17-itemCommandAction|16|196-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|17|195-preAction
        } else if (item == imageItem17) {
            if (command == goToMessages) {//GEN-END:|17-itemCommandAction|17|195-preAction
                // write pre-action user code here
                switchDisplayable(null, getMessages());//GEN-LINE:|17-itemCommandAction|18|195-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|19|200-preAction
        } else if (item == imageItem18) {
            if (command == goToAlerts) {//GEN-END:|17-itemCommandAction|19|200-preAction
                // write pre-action user code here
                switchDisplayable(null, getAlerts());//GEN-LINE:|17-itemCommandAction|20|200-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|21|201-preAction
        } else if (item == imageItem19) {
            if (command == goToMessages) {//GEN-END:|17-itemCommandAction|21|201-preAction
                // write pre-action user code here
                switchDisplayable(null, getMessages());//GEN-LINE:|17-itemCommandAction|22|201-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|23|57-preAction
        } else if (item == imageItem2) {
            if (command == goToSchedule) {//GEN-END:|17-itemCommandAction|23|57-preAction
                // write pre-action user code here
                switchDisplayable(null, getSchedule());//GEN-LINE:|17-itemCommandAction|24|57-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|25|243-preAction
        } else if (item == imageItem20) {
            if (command == goToAlerts) {//GEN-END:|17-itemCommandAction|25|243-preAction
                // write pre-action user code here
//GEN-LINE:|17-itemCommandAction|26|243-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|27|244-preAction
        } else if (item == imageItem21) {
            if (command == goToMessages) {//GEN-END:|17-itemCommandAction|27|244-preAction
                // write pre-action user code here
//GEN-LINE:|17-itemCommandAction|28|244-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|29|249-preAction
        } else if (item == imageItem22) {
            if (command == goToSendSMS) {//GEN-END:|17-itemCommandAction|29|249-preAction
                // write pre-action user code here
                switchDisplayable(null, getSendSMS());//GEN-LINE:|17-itemCommandAction|30|249-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|31|238-preAction
        } else if (item == imageItem23) {
            if (command == goToAlerts) {//GEN-END:|17-itemCommandAction|31|238-preAction
                // write pre-action user code here
                switchDisplayable(null, getAlerts());//GEN-LINE:|17-itemCommandAction|32|238-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|33|240-preAction
        } else if (item == imageItem24) {
            if (command == goToMessages) {//GEN-END:|17-itemCommandAction|33|240-preAction
                // write pre-action user code here
                switchDisplayable(null, getMessages());//GEN-LINE:|17-itemCommandAction|34|240-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|35|61-preAction
        } else if (item == imageItem3) {
            if (command == goToClasses) {//GEN-END:|17-itemCommandAction|35|61-preAction
                // write pre-action user code here
                switchDisplayable(null, getClasses());//GEN-LINE:|17-itemCommandAction|36|61-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|37|147-preAction
        } else if (item == imageItem4) {
            if (command == goToSupportMaterials) {//GEN-END:|17-itemCommandAction|37|147-preAction
                // write pre-action user code here
                switchDisplayable(null, getSupportMaterial());//GEN-LINE:|17-itemCommandAction|38|147-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|39|109-preAction
        } else if (item == imageItem5) {
            if (command == goToInfo) {//GEN-END:|17-itemCommandAction|39|109-preAction
                // write pre-action user code here
                switchDisplayable(null, getInformation());//GEN-LINE:|17-itemCommandAction|40|109-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|41|160-preAction
        } else if (item == imageItem6) {
            if (command == goToAlerts) {//GEN-END:|17-itemCommandAction|41|160-preAction
                // write pre-action user code here
                switchDisplayable(null, getAlerts());//GEN-LINE:|17-itemCommandAction|42|160-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|43|172-preAction
        } else if (item == imageItem7) {
            if (command == goToMessages) {//GEN-END:|17-itemCommandAction|43|172-preAction
                // write pre-action user code here
                switchDisplayable(null, getMessages());//GEN-LINE:|17-itemCommandAction|44|172-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|45|174-preAction
        } else if (item == imageItem8) {
            if (command == goToAlerts) {//GEN-END:|17-itemCommandAction|45|174-preAction
                // write pre-action user code here
                switchDisplayable(null, getAlerts());//GEN-LINE:|17-itemCommandAction|46|174-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|47|177-preAction
        } else if (item == imageItem9) {
            if (command == goToMessages) {//GEN-END:|17-itemCommandAction|47|177-preAction
                // write pre-action user code here
                switchDisplayable(null, getMessages());//GEN-LINE:|17-itemCommandAction|48|177-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|49|247-preAction
        } else if (item == inbox) {
            if (command == goToInbox) {//GEN-END:|17-itemCommandAction|49|247-preAction
                // write pre-action user code here
                switchDisplayable(null, getInboxScreen());//GEN-LINE:|17-itemCommandAction|50|247-postAction
                // write post-action user code here
            }//GEN-BEGIN:|17-itemCommandAction|51|17-postItemCommandAction
        }//GEN-END:|17-itemCommandAction|51|17-postItemCommandAction
        // write post-action user code here
    }//GEN-BEGIN:|17-itemCommandAction|52|
//</editor-fold>//GEN-END:|17-itemCommandAction|52|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToSchedule ">//GEN-BEGIN:|56-getter|0|56-preInit
    /**
     * Returns an initiliazed instance of goToSchedule component.
     * @return the initialized component instance
     */
    public Command getGoToSchedule() {
        if (goToSchedule == null) {//GEN-END:|56-getter|0|56-preInit
            // write pre-init user code here
            goToSchedule = new Command("Confirmar", Command.SCREEN, 0);//GEN-LINE:|56-getter|1|56-postInit

        }//GEN-BEGIN:|56-getter|2|
        return goToSchedule;
    }
//</editor-fold>//GEN-END:|56-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToClasses ">//GEN-BEGIN:|60-getter|0|60-preInit
    /**
     * Returns an initiliazed instance of goToClasses component.
     * @return the initialized component instance
     */
    public Command getGoToClasses() {
        if (goToClasses == null) {//GEN-END:|60-getter|0|60-preInit
            // write pre-init user code here
            goToClasses = new Command("Confirmar", Command.SCREEN, 0);//GEN-LINE:|60-getter|1|60-postInit

        }//GEN-BEGIN:|60-getter|2|
        return goToClasses;
    }
//</editor-fold>//GEN-END:|60-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToAlerts ">//GEN-BEGIN:|63-getter|0|63-preInit
    /**
     * Returns an initiliazed instance of goToAlerts component.
     * @return the initialized component instance
     */
    public Command getGoToAlerts() {
        if (goToAlerts == null) {//GEN-END:|63-getter|0|63-preInit
            // write pre-init user code here
            goToAlerts = new Command("Confirmar", Command.SCREEN, 0);//GEN-LINE:|63-getter|1|63-postInit

        }//GEN-BEGIN:|63-getter|2|
        return goToAlerts;
    }
//</editor-fold>//GEN-END:|63-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToMessages ">//GEN-BEGIN:|66-getter|0|66-preInit
    /**
     * Returns an initiliazed instance of goToMessages component.
     * @return the initialized component instance
     */
    public Command getGoToMessages() {
        if (goToMessages == null) {//GEN-END:|66-getter|0|66-preInit
            // write pre-init user code here
            goToMessages = new Command("Confirmar", Command.SCREEN, 0);//GEN-LINE:|66-getter|1|66-postInit

        }//GEN-BEGIN:|66-getter|2|
        return goToMessages;
    }
//</editor-fold>//GEN-END:|66-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToMainMenu ">//GEN-BEGIN:|69-getter|0|69-preInit
    /**
     * Returns an initiliazed instance of goToMainMenu component.
     * @return the initialized component instance
     */
    public Command getGoToMainMenu() {
        if (goToMainMenu == null) {//GEN-END:|69-getter|0|69-preInit
            // write pre-init user code here
            goToMainMenu = new Command("Back", Command.BACK, 0);//GEN-LINE:|69-getter|1|69-postInit
            // write post-init user code here
        }//GEN-BEGIN:|69-getter|2|
        return goToMainMenu;
    }
//</editor-fold>//GEN-END:|69-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: backClasses ">//GEN-BEGIN:|72-getter|0|72-preInit
    /**
     * Returns an initiliazed instance of backClasses component.
     * @return the initialized component instance
     */
    public Command getBackClasses() {
        if (backClasses == null) {//GEN-END:|72-getter|0|72-preInit
            // write pre-init user code here
            backClasses = new Command("Back", Command.BACK, 0);//GEN-LINE:|72-getter|1|72-postInit
            // write post-init user code here
        }//GEN-BEGIN:|72-getter|2|
        return backClasses;
    }
//</editor-fold>//GEN-END:|72-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: backAlerts ">//GEN-BEGIN:|74-getter|0|74-preInit
    /**
     * Returns an initiliazed instance of backAlerts component.
     * @return the initialized component instance
     */
    public Command getBackAlerts() {
        if (backAlerts == null) {//GEN-END:|74-getter|0|74-preInit
            // write pre-init user code here
            backAlerts = new Command("Back", Command.BACK, 0);//GEN-LINE:|74-getter|1|74-postInit
            // write post-init user code here
        }//GEN-BEGIN:|74-getter|2|
        return backAlerts;
    }
//</editor-fold>//GEN-END:|74-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: backSendSMS ">//GEN-BEGIN:|76-getter|0|76-preInit
    /**
     * Returns an initiliazed instance of backSendSMS component.
     * @return the initialized component instance
     */
    public Command getBackSendSMS() {
        if (backSendSMS == null) {//GEN-END:|76-getter|0|76-preInit
            // write pre-init user code here
            backSendSMS = new Command("Back", Command.BACK, 0);//GEN-LINE:|76-getter|1|76-postInit
            // write post-init user code here
        }//GEN-BEGIN:|76-getter|2|
        return backSendSMS;
    }
//</editor-fold>//GEN-END:|76-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem2 ">//GEN-BEGIN:|55-getter|0|55-preInit
    /**
     * Returns an initiliazed instance of imageItem2 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem2() {
        if (imageItem2 == null) {//GEN-END:|55-getter|0|55-preInit
            // write pre-init user code here
            imageItem2 = new ImageItem("Horario", getHorario(), ImageItem.LAYOUT_CENTER | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER | ImageItem.LAYOUT_NEWLINE_BEFORE | ImageItem.LAYOUT_NEWLINE_AFTER, "<Missing Image>", Item.PLAIN);//GEN-BEGIN:|55-getter|1|55-postInit
            imageItem2.addCommand(getGoToSchedule());
            imageItem2.setItemCommandListener(this);
            imageItem2.setDefaultCommand(getGoToSchedule());//GEN-END:|55-getter|1|55-postInit

        }//GEN-BEGIN:|55-getter|2|
        return imageItem2;
    }
//</editor-fold>//GEN-END:|55-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem3 ">//GEN-BEGIN:|59-getter|0|59-preInit
    /**
     * Returns an initiliazed instance of imageItem3 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem3() {
        if (imageItem3 == null) {//GEN-END:|59-getter|0|59-preInit
            // write pre-init user code here
            imageItem3 = new ImageItem("Cadeiras", getCadeiras(), ImageItem.LAYOUT_CENTER | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER | ImageItem.LAYOUT_NEWLINE_BEFORE | Item.LAYOUT_SHRINK | Item.LAYOUT_VSHRINK, "<Missing Image>", Item.PLAIN);//GEN-BEGIN:|59-getter|1|59-postInit
            imageItem3.addCommand(getGoToClasses());
            imageItem3.setItemCommandListener(this);
            imageItem3.setDefaultCommand(getGoToClasses());//GEN-END:|59-getter|1|59-postInit
            // write post-init user code here
        }//GEN-BEGIN:|59-getter|2|
        return imageItem3;
    }
//</editor-fold>//GEN-END:|59-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: schedule ">//GEN-BEGIN:|51-getter|0|51-preInit
    /**
     * Returns an initiliazed instance of schedule component.
     * @return the initialized component instance
     */
    public Form getSchedule() {
        if (schedule == null) {//GEN-END:|51-getter|0|51-preInit

            schedule = new Form("Horario", new Item[]{getImageItem8(), getImageItem9(), getSpacer4(), getChoiceGroup()});//GEN-BEGIN:|51-getter|1|51-postInit
            schedule.addCommand(getGoToMainMenu());
            schedule.addCommand(getGoToDay());
            schedule.setCommandListener(this);//GEN-END:|51-getter|1|51-postInit


        }//GEN-BEGIN:|51-getter|2|
        return schedule;
    }
//</editor-fold>//GEN-END:|51-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: classes ">//GEN-BEGIN:|52-getter|0|52-preInit
    /**
     * Returns an initiliazed instance of classes component.
     * @return the initialized component instance
     */
    public Form getClasses() {
        if (classes == null) {//GEN-END:|52-getter|0|52-preInit
            // write pre-init user code here
            classes = new Form("Cadeiras", new Item[]{getImageItem10(), getImageItem11(), getSpacer5(), getCoursesList()});//GEN-BEGIN:|52-getter|1|52-postInit
            classes.addCommand(getBackClasses());
            classes.addCommand(getGoToClasseX());
            classes.setCommandListener(this);//GEN-END:|52-getter|1|52-postInit
            // write post-init user code here
        }//GEN-BEGIN:|52-getter|2|
        return classes;
    }
//</editor-fold>//GEN-END:|52-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: alerts ">//GEN-BEGIN:|53-getter|0|53-preInit
    /**
     * Returns an initiliazed instance of alerts component.
     * @return the initialized component instance
     */
    public Form getAlerts() {
        if (alerts == null) {//GEN-END:|53-getter|0|53-preInit
            // write pre-init user code here
            alerts = new Form("Alertas", new Item[]{getAlertText()});//GEN-BEGIN:|53-getter|1|53-postInit
            alerts.addCommand(getBackAlerts());
            alerts.setCommandListener(this);//GEN-END:|53-getter|1|53-postInit

        }//GEN-BEGIN:|53-getter|2|
        return alerts;
    }
//</editor-fold>//GEN-END:|53-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: sendSMS ">//GEN-BEGIN:|54-getter|0|54-preInit
    /**
     * Returns an initiliazed instance of sendSMS component.
     * @return the initialized component instance
     */
    public Form getSendSMS() {
        if (sendSMS == null) {//GEN-END:|54-getter|0|54-preInit
            // write pre-init user code here
            sendSMS = new Form("Enviar Mensagem", new Item[]{getSmsReceiver(), getSpacer(), getSmsText()});//GEN-BEGIN:|54-getter|1|54-postInit
            sendSMS.addCommand(getBackSendSMS());
            sendSMS.addCommand(getOkSendSMS());
            sendSMS.setCommandListener(this);//GEN-END:|54-getter|1|54-postInit

        }//GEN-BEGIN:|54-getter|2|
        return sendSMS;
    }
//</editor-fold>//GEN-END:|54-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: fctuc ">//GEN-BEGIN:|86-getter|0|86-preInit
    /**
     * Returns an initiliazed instance of fctuc component.
     * @return the initialized component instance
     */
    public Image getFctuc() {
        if (fctuc == null) {//GEN-END:|86-getter|0|86-preInit
            // write pre-init user code here
            try {//GEN-BEGIN:|86-getter|1|86-@java.io.IOException
                fctuc = Image.createImage("/images/fctuc.png");
            } catch (java.io.IOException e) {//GEN-END:|86-getter|1|86-@java.io.IOException
                e.printStackTrace();
            }//GEN-LINE:|86-getter|2|86-postInit
            // write post-init user code here
        }//GEN-BEGIN:|86-getter|3|
        return fctuc;
    }
//</editor-fold>//GEN-END:|86-getter|3|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: backClasseX ">//GEN-BEGIN:|88-getter|0|88-preInit
    /**
     * Returns an initiliazed instance of backClasseX component.
     * @return the initialized component instance
     */
    public Command getBackClasseX() {
        if (backClasseX == null) {//GEN-END:|88-getter|0|88-preInit
            // write pre-init user code here
            backClasseX = new Command("Back", Command.BACK, 0);//GEN-LINE:|88-getter|1|88-postInit
            // write post-init user code here
        }//GEN-BEGIN:|88-getter|2|
        return backClasseX;
    }
//</editor-fold>//GEN-END:|88-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToClasseX ">//GEN-BEGIN:|96-getter|0|96-preInit
    /**
     * Returns an initiliazed instance of goToClasseX component.
     * @return the initialized component instance
     */
    public Command getGoToClasseX() {
        if (goToClasseX == null) {//GEN-END:|96-getter|0|96-preInit
            // write pre-init user code here
            goToClasseX = new Command("Screen", Command.SCREEN, 0);//GEN-LINE:|96-getter|1|96-postInit
            // write post-init user code here
        }//GEN-BEGIN:|96-getter|2|
        return goToClasseX;
    }
//</editor-fold>//GEN-END:|96-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: backSupportMaterial ">//GEN-BEGIN:|99-getter|0|99-preInit
    /**
     * Returns an initiliazed instance of backSupportMaterial component.
     * @return the initialized component instance
     */
    public Command getBackSupportMaterial() {
        if (backSupportMaterial == null) {//GEN-END:|99-getter|0|99-preInit
            // write pre-init user code here
            backSupportMaterial = new Command("Back", Command.BACK, 0);//GEN-LINE:|99-getter|1|99-postInit
            // write post-init user code here
        }//GEN-BEGIN:|99-getter|2|
        return backSupportMaterial;
    }
//</editor-fold>//GEN-END:|99-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: backInformation ">//GEN-BEGIN:|102-getter|0|102-preInit
    /**
     * Returns an initiliazed instance of backInformation component.
     * @return the initialized component instance
     */
    public Command getBackInformation() {
        if (backInformation == null) {//GEN-END:|102-getter|0|102-preInit
            // write pre-init user code here
            backInformation = new Command("Back", Command.BACK, 0);//GEN-LINE:|102-getter|1|102-postInit
            // write post-init user code here
        }//GEN-BEGIN:|102-getter|2|
        return backInformation;
    }
//</editor-fold>//GEN-END:|102-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToSupportMaterial ">//GEN-BEGIN:|106-getter|0|106-preInit
    /**
     * Returns an initiliazed instance of goToSupportMaterial component.
     * @return the initialized component instance
     */
    public Command getGoToSupportMaterial() {
        if (goToSupportMaterial == null) {//GEN-END:|106-getter|0|106-preInit
            // write pre-init user code here
            goToSupportMaterial = new Command("Screen", Command.SCREEN, 0);//GEN-LINE:|106-getter|1|106-postInit
            // write post-init user code here
        }//GEN-BEGIN:|106-getter|2|
        return goToSupportMaterial;
    }
//</editor-fold>//GEN-END:|106-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToInfo ">//GEN-BEGIN:|108-getter|0|108-preInit
    /**
     * Returns an initiliazed instance of goToInfo component.
     * @return the initialized component instance
     */
    public Command getGoToInfo() {
        if (goToInfo == null) {//GEN-END:|108-getter|0|108-preInit
            // write pre-init user code here
            goToInfo = new Command("Confirmar", Command.SCREEN, 0);//GEN-LINE:|108-getter|1|108-postInit




        }//GEN-BEGIN:|108-getter|2|
        return goToInfo;
    }
//</editor-fold>//GEN-END:|108-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: classeX ">//GEN-BEGIN:|87-getter|0|87-preInit
    /**
     * Returns an initiliazed instance of classeX component.
     * @return the initialized component instance
     */
    public Form getClasseX() {
        if (classeX == null) {//GEN-END:|87-getter|0|87-preInit
            // write pre-init user code here
            classeX = new Form("", new Item[]{getImageItem6(), getImageItem7(), getSpacer3(), getImageItem4(), getImageItem5()});//GEN-BEGIN:|87-getter|1|87-postInit
            classeX.addCommand(getBackClasseX());
            classeX.setCommandListener(this);//GEN-END:|87-getter|1|87-postInit

        }//GEN-BEGIN:|87-getter|2|
        return classeX;
    }
//</editor-fold>//GEN-END:|87-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem4 ">//GEN-BEGIN:|91-getter|0|91-preInit
    /**
     * Returns an initiliazed instance of imageItem4 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem4() {
        if (imageItem4 == null) {//GEN-END:|91-getter|0|91-preInit
            // write pre-init user code here
            imageItem4 = new ImageItem("Material Apoio", getMaterialApoio(), ImageItem.LAYOUT_CENTER | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER | ImageItem.LAYOUT_NEWLINE_BEFORE | ImageItem.LAYOUT_NEWLINE_AFTER, "<Missing Image>", Item.PLAIN);//GEN-BEGIN:|91-getter|1|91-postInit
            imageItem4.addCommand(getGoToSupportMaterials());
            imageItem4.setItemCommandListener(this);
            imageItem4.setDefaultCommand(getGoToSupportMaterials());//GEN-END:|91-getter|1|91-postInit
            // write post-init user code here
        }//GEN-BEGIN:|91-getter|2|
        return imageItem4;
    }
//</editor-fold>//GEN-END:|91-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem5 ">//GEN-BEGIN:|105-getter|0|105-preInit
    /**
     * Returns an initiliazed instance of imageItem5 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem5() {
        if (imageItem5 == null) {//GEN-END:|105-getter|0|105-preInit
            // write pre-init user code here
            imageItem5 = new ImageItem("Info Geral", getNotas(), ImageItem.LAYOUT_CENTER | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER | ImageItem.LAYOUT_NEWLINE_BEFORE | ImageItem.LAYOUT_NEWLINE_AFTER, "<Missing Image>", Item.PLAIN);//GEN-BEGIN:|105-getter|1|105-postInit
            imageItem5.addCommand(getGoToInfo());
            imageItem5.setItemCommandListener(this);
            imageItem5.setDefaultCommand(getGoToInfo());//GEN-END:|105-getter|1|105-postInit
            // write post-init user code here
        }//GEN-BEGIN:|105-getter|2|
        return imageItem5;
    }
//</editor-fold>//GEN-END:|105-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: supportMaterial ">//GEN-BEGIN:|93-getter|0|93-preInit
    /**
     * Returns an initiliazed instance of supportMaterial component.
     * @return the initialized component instance
     */
    public Form getSupportMaterial() {
        if (supportMaterial == null) {//GEN-END:|93-getter|0|93-preInit
            // write pre-init user code here
            supportMaterial = new Form("Material de Apoio", new Item[]{getImageItem12(), getImageItem13(), getSpacer6(), getSupportMaterials()});//GEN-BEGIN:|93-getter|1|93-postInit
            supportMaterial.addCommand(getBackSupportMaterial());
            supportMaterial.addCommand(getGoToDocument());
            supportMaterial.setCommandListener(this);//GEN-END:|93-getter|1|93-postInit
            // write post-init user code here
        }//GEN-BEGIN:|93-getter|2|
        return supportMaterial;
    }
//</editor-fold>//GEN-END:|93-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: information ">//GEN-BEGIN:|94-getter|0|94-preInit
    /**
     * Returns an initiliazed instance of information component.
     * @return the initialized component instance
     */
    public Form getInformation() {
        if (information == null) {//GEN-END:|94-getter|0|94-preInit
            // write pre-init user code here
            information = new Form("Informacao", new Item[]{getImageItem14(), getImageItem15(), getSpacer7(), getCourseInfo()});//GEN-BEGIN:|94-getter|1|94-postInit
            information.addCommand(getBackInformation());
            information.setCommandListener(this);//GEN-END:|94-getter|1|94-postInit
            // write post-init user code here
        }//GEN-BEGIN:|94-getter|2|
        return information;
    }
//</editor-fold>//GEN-END:|94-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: materialApoio ">//GEN-BEGIN:|92-getter|0|92-preInit
    /**
     * Returns an initiliazed instance of materialApoio component.
     * @return the initialized component instance
     */
    public Image getMaterialApoio() {
        if (materialApoio == null) {//GEN-END:|92-getter|0|92-preInit
            // write pre-init user code here
            try {//GEN-BEGIN:|92-getter|1|92-@java.io.IOException
                materialApoio = Image.createImage("/images/material_apoio2.png");
            } catch (java.io.IOException e) {//GEN-END:|92-getter|1|92-@java.io.IOException
                e.printStackTrace();
            }//GEN-LINE:|92-getter|2|92-postInit
            // write post-init user code here
        }//GEN-BEGIN:|92-getter|3|
        return materialApoio;
    }
//</editor-fold>//GEN-END:|92-getter|3|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: notas ">//GEN-BEGIN:|112-getter|0|112-preInit
    /**
     * Returns an initiliazed instance of notas component.
     * @return the initialized component instance
     */
    public Image getNotas() {
        if (notas == null) {//GEN-END:|112-getter|0|112-preInit
            // write pre-init user code here
            try {//GEN-BEGIN:|112-getter|1|112-@java.io.IOException
                notas = Image.createImage("/images/cadeiras_informacoes.png");
            } catch (java.io.IOException e) {//GEN-END:|112-getter|1|112-@java.io.IOException
                e.printStackTrace();
            }//GEN-LINE:|112-getter|2|112-postInit
            // write post-init user code here
        }//GEN-BEGIN:|112-getter|3|
        return notas;
    }
//</editor-fold>//GEN-END:|112-getter|3|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToDay ">//GEN-BEGIN:|116-getter|0|116-preInit
    /**
     * Returns an initiliazed instance of goToDay component.
     * @return the initialized component instance
     */
    public Command getGoToDay() {
        if (goToDay == null) {//GEN-END:|116-getter|0|116-preInit
            // write pre-init user code here
            goToDay = new Command("Screen", Command.SCREEN, 0);//GEN-LINE:|116-getter|1|116-postInit
            // write post-init user code here
        }//GEN-BEGIN:|116-getter|2|
        return goToDay;
    }
//</editor-fold>//GEN-END:|116-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: choiceGroup ">//GEN-BEGIN:|120-getter|0|120-preInit
    /**
     * Returns an initiliazed instance of choiceGroup component.
     * @return the initialized component instance
     */
    public ChoiceGroup getChoiceGroup() {
        if (choiceGroup == null) {//GEN-END:|120-getter|0|120-preInit
            // write pre-init user code here
            choiceGroup = new ChoiceGroup("Dias", Choice.EXCLUSIVE);//GEN-LINE:|120-getter|1|120-postInit


            for (int i = 0; i < 5; i++) {
                choiceGroup.append(this.weekDays[i], null);
            }


// write post-init user code here
        }//GEN-BEGIN:|120-getter|2|
        return choiceGroup;
    }
//</editor-fold>//GEN-END:|120-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: day ">//GEN-BEGIN:|115-getter|0|115-preInit
    /**
     * Returns an initiliazed instance of day component.
     * @return the initialized component instance
     */
    public Form getDay() {
        if (day == null) {//GEN-END:|115-getter|0|115-preInit
            //  display.setCurrent(day);
            day = new Form(this.weekDays[this.selectedDay], new Item[]{getImageItem16(), getImageItem17(), getSpacer8(), getDaySchedule()});//GEN-BEGIN:|115-getter|1|115-postInit
            day.addCommand(getBackDay());
            day.setCommandListener(this);//GEN-END:|115-getter|1|115-postInit

        }//GEN-BEGIN:|115-getter|2|
        return day;
    }
//</editor-fold>//GEN-END:|115-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: backDay ">//GEN-BEGIN:|121-getter|0|121-preInit
    /**
     * Returns an initiliazed instance of backDay component.
     * @return the initialized component instance
     */
    public Command getBackDay() {
        if (backDay == null) {//GEN-END:|121-getter|0|121-preInit
            // write pre-init user code here
            backDay = new Command("Back", Command.EXIT, 0);//GEN-LINE:|121-getter|1|121-postInit
            // write post-init user code here
        }//GEN-BEGIN:|121-getter|2|
        return backDay;
    }
//</editor-fold>//GEN-END:|121-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: coursesList ">//GEN-BEGIN:|126-getter|0|126-preInit
    /**
     * Returns an initiliazed instance of coursesList component.
     * @return the initialized component instance
     */
    public ChoiceGroup getCoursesList() {
        if (coursesList == null) {//GEN-END:|126-getter|0|126-preInit
            // write pre-init user code here
            coursesList = new ChoiceGroup("", Choice.EXCLUSIVE);//GEN-LINE:|126-getter|1|126-postInit

            String info = conn.processRequest("getCadeiras", null);

            String[] temp = split(info, ",");

            for (int i = 1; i < temp.length; i++) {
                if (!("\n".equals(temp[i]))) {
                    coursesList.append(temp[i], null);
                }
            }



// write post-init user code here
        }//GEN-BEGIN:|126-getter|2|
        return coursesList;
    }
//</editor-fold>//GEN-END:|126-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: supportMaterials ">//GEN-BEGIN:|128-getter|0|128-preInit
    /**
     * Returns an initiliazed instance of supportMaterials component.
     * @return the initialized component instance
     */
    public ChoiceGroup getSupportMaterials() {
        if (supportMaterials == null) {//GEN-END:|128-getter|0|128-preInit

            supportMaterials = new ChoiceGroup("Materiais Disponiveis", Choice.EXCLUSIVE);//GEN-LINE:|128-getter|1|128-postInit
//    for (int i = 0; i < totalMaterials; i++) {
//        supportMaterials.append("MRC " + i, null);
//    }
            supportMaterials.append("Aula 1", null);
            supportMaterials.append("Aula 2", null);
        }//GEN-BEGIN:|128-getter|2|
        return supportMaterials;
    }
//</editor-fold>//GEN-END:|128-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToDocument ">//GEN-BEGIN:|129-getter|0|129-preInit
    /**
     * Returns an initiliazed instance of goToDocument component.
     * @return the initialized component instance
     */
    public Command getGoToDocument() {
        if (goToDocument == null) {//GEN-END:|129-getter|0|129-preInit
            // write pre-init user code here
            goToDocument = new Command("Ver", Command.SCREEN, 0);//GEN-LINE:|129-getter|1|129-postInit
            // write post-init user code here
        }//GEN-BEGIN:|129-getter|2|
        return goToDocument;
    }
//</editor-fold>//GEN-END:|129-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: document ">//GEN-BEGIN:|131-getter|0|131-preInit
    /**
     * Returns an initiliazed instance of document component.
     * @return the initialized component instance
     */
    public Form getDocument() {
        if (document == null) {//GEN-END:|131-getter|0|131-preInit
            // write pre-init user code here
            document = new Form(this.supportMaterials.getString(supportMaterials.getSelectedIndex()), new Item[]{getImageItem18(), getImageItem19(), getSpacer9(), getCurrentDocument()});//GEN-BEGIN:|131-getter|1|131-postInit
            document.addCommand(getBackDocument());
            document.setCommandListener(this);//GEN-END:|131-getter|1|131-postInit
            // write post-init user code here
        }//GEN-BEGIN:|131-getter|2|
        return document;
    }
//</editor-fold>//GEN-END:|131-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: backDocument ">//GEN-BEGIN:|133-getter|0|133-preInit
    /**
     * Returns an initiliazed instance of backDocument component.
     * @return the initialized component instance
     */
    public Command getBackDocument() {
        if (backDocument == null) {//GEN-END:|133-getter|0|133-preInit
            // write pre-init user code here
            backDocument = new Command("Back", Command.BACK, 0);//GEN-LINE:|133-getter|1|133-postInit
            // write post-init user code here
        }//GEN-BEGIN:|133-getter|2|
        return backDocument;
    }
//</editor-fold>//GEN-END:|133-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: currentDocument ">//GEN-BEGIN:|137-getter|0|137-preInit
    /**
     * Returns an initiliazed instance of currentDocument component.
     * @return the initialized component instance
     */
    public StringItem getCurrentDocument() {
        if (currentDocument == null) {//GEN-END:|137-getter|0|137-preInit
            // write pre-init user code here
            currentDocument = new StringItem("", null, Item.PLAIN);//GEN-BEGIN:|137-getter|1|137-postInit
            currentDocument.setFont(getDayFont());//GEN-END:|137-getter|1|137-postInit

            currentDocument.setText(conn.downloadMaterialdeApoio(supportMaterials.getString(supportMaterials.getSelectedIndex())));
// write post-init user code here
        }//GEN-BEGIN:|137-getter|2|
        return currentDocument;
    }
//</editor-fold>//GEN-END:|137-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: daySchedule ">//GEN-BEGIN:|138-getter|0|138-preInit
    /**
     * Returns an initiliazed instance of daySchedule component.
     * @return the initialized component instance
     */
    public StringItem getDaySchedule() {
        if (daySchedule == null) {//GEN-END:|138-getter|0|138-preInit
            // write pre-init user code here
            daySchedule = new StringItem("", null);//GEN-BEGIN:|138-getter|1|138-postInit
            daySchedule.setLayout(ImageItem.LAYOUT_DEFAULT | ImageItem.LAYOUT_NEWLINE_BEFORE);
            daySchedule.setFont(getDayFont());//GEN-END:|138-getter|1|138-postInit
            String weekday = (this.selectedDay + 2) + "f";

            String info = conn.processRequest("getHorarios", weekday);
            System.out.println("\t\tSocio ja tenho os dados, vou formatar isto!");
            String[] linhas = split(info, ";");
            String[] aux;
            String mostra = "";

            for (int i = 0; i < linhas.length - 1; i++) {
                System.out.println("\t\tlinhas" + i + ": " + linhas[i]);
                aux = split(linhas[i], ",");
                mostra += aux[0] + " " + aux[1] + "\n";
            }

            System.out.println("\t\tinfo: " + info);
            System.out.println("\t\tmostra: " + mostra);
            daySchedule.setText(mostra);
            //daySchedule.
        }//GEN-BEGIN:|138-getter|2|
        return daySchedule;
    }
//</editor-fold>//GEN-END:|138-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: gotoMaterials ">//GEN-BEGIN:|141-getter|0|141-preInit
    /**
     * Returns an initiliazed instance of gotoMaterials component.
     * @return the initialized component instance
     */
    public Command getGotoMaterials() {
        if (gotoMaterials == null) {//GEN-END:|141-getter|0|141-preInit
            // write pre-init user code here
            gotoMaterials = new Command("Screen", Command.SCREEN, 0);//GEN-LINE:|141-getter|1|141-postInit
            // write post-init user code here
        }//GEN-BEGIN:|141-getter|2|
        return gotoMaterials;
    }
//</editor-fold>//GEN-END:|141-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: courseInfo ">//GEN-BEGIN:|140-getter|0|140-preInit
    /**
     * Returns an initiliazed instance of courseInfo component.
     * @return the initialized component instance
     */
    public StringItem getCourseInfo() {
        if (courseInfo == null) {//GEN-END:|140-getter|0|140-preInit
            // write pre-init user code here
            courseInfo = new StringItem("", null);//GEN-BEGIN:|140-getter|1|140-postInit
            courseInfo.setFont(getDayFont());//GEN-END:|140-getter|1|140-postInit
            // write post-init user code here
            String info = conn.processRequest("getAll", coursesList.getString(this.cadeiraActual));
            System.out.println(info);
            String[] aux = split(info, ",");
            String resultado = "Nome:     " + aux[0] + "\n\n"
                    + "ECTS:     " + aux[2] + "\n"
                    + "Semestre: " + aux[1] + "\n"
                    + "Codigo:   " + aux[3] + "\n"
                    + "Tipo:     " + aux[5] + "\n";

            this.courseInfo.setText(resultado);
        }//GEN-BEGIN:|140-getter|2|
        return courseInfo;
    }
//</editor-fold>//GEN-END:|140-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: screenCommand ">//GEN-BEGIN:|144-getter|0|144-preInit
    /**
     * Returns an initiliazed instance of screenCommand component.
     * @return the initialized component instance
     */
    public Command getScreenCommand() {
        if (screenCommand == null) {//GEN-END:|144-getter|0|144-preInit
            // write pre-init user code here
            screenCommand = new Command("Screen", Command.SCREEN, 0);//GEN-LINE:|144-getter|1|144-postInit
            // write post-init user code here
        }//GEN-BEGIN:|144-getter|2|
        return screenCommand;
    }
//</editor-fold>//GEN-END:|144-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToSupportMaterials ">//GEN-BEGIN:|146-getter|0|146-preInit
    /**
     * Returns an initiliazed instance of goToSupportMaterials component.
     * @return the initialized component instance
     */
    public Command getGoToSupportMaterials() {
        if (goToSupportMaterials == null) {//GEN-END:|146-getter|0|146-preInit
            // write pre-init user code here
            goToSupportMaterials = new Command("Confirmar", Command.SCREEN, 0);//GEN-LINE:|146-getter|1|146-postInit
            // write post-init user code here
        }//GEN-BEGIN:|146-getter|2|
        return goToSupportMaterials;
    }
//</editor-fold>//GEN-END:|146-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: smsReceiver ">//GEN-BEGIN:|149-getter|0|149-preInit
    /**
     * Returns an initiliazed instance of smsReceiver component.
     * @return the initialized component instance
     */
    public TextField getSmsReceiver() {
        if (smsReceiver == null) {//GEN-END:|149-getter|0|149-preInit
            // write pre-init user code here
            smsReceiver = new TextField("Destinatario", null, 32, TextField.ANY);//GEN-LINE:|149-getter|1|149-postInit
            // write post-init user code here
        }//GEN-BEGIN:|149-getter|2|
        return smsReceiver;
    }
//</editor-fold>//GEN-END:|149-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: spacer ">//GEN-BEGIN:|150-getter|0|150-preInit
    /**
     * Returns an initiliazed instance of spacer component.
     * @return the initialized component instance
     */
    public Spacer getSpacer() {
        if (spacer == null) {//GEN-END:|150-getter|0|150-preInit
            // write pre-init user code here
            spacer = new Spacer(16, 1);//GEN-LINE:|150-getter|1|150-postInit
            // write post-init user code here
        }//GEN-BEGIN:|150-getter|2|
        return spacer;
    }
//</editor-fold>//GEN-END:|150-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: smsText ">//GEN-BEGIN:|151-getter|0|151-preInit
    /**
     * Returns an initiliazed instance of smsText component.
     * @return the initialized component instance
     */
    public TextField getSmsText() {
        if (smsText == null) {//GEN-END:|151-getter|0|151-preInit
            // write pre-init user code here
            smsText = new TextField("Texto da mensagem", null, 32, TextField.ANY);//GEN-LINE:|151-getter|1|151-postInit
            // write post-init user code here
        }//GEN-BEGIN:|151-getter|2|
        return smsText;
    }
//</editor-fold>//GEN-END:|151-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: mensagemOn ">//GEN-BEGIN:|153-getter|0|153-preInit
    /**
     * Returns an initiliazed instance of mensagemOn component.
     * @return the initialized component instance
     */
    public Image getMensagemOn() {
        if (mensagemOn == null) {//GEN-END:|153-getter|0|153-preInit
            // write pre-init user code here
            try {//GEN-BEGIN:|153-getter|1|153-@java.io.IOException
                mensagemOn = Image.createImage("/images/mensagem_nova.png");
            } catch (java.io.IOException e) {//GEN-END:|153-getter|1|153-@java.io.IOException
                e.printStackTrace();
            }//GEN-LINE:|153-getter|2|153-postInit
            // write post-init user code here
        }//GEN-BEGIN:|153-getter|3|
        return mensagemOn;
    }
//</editor-fold>//GEN-END:|153-getter|3|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: alertaOn ">//GEN-BEGIN:|154-getter|0|154-preInit
    /**
     * Returns an initiliazed instance of alertaOn component.
     * @return the initialized component instance
     */
    public Image getAlertaOn() {
        if (alertaOn == null) {//GEN-END:|154-getter|0|154-preInit
            // write pre-init user code here
            try {//GEN-BEGIN:|154-getter|1|154-@java.io.IOException
                alertaOn = Image.createImage("/images/alerta_on.png");
            } catch (java.io.IOException e) {//GEN-END:|154-getter|1|154-@java.io.IOException
                e.printStackTrace();
            }//GEN-LINE:|154-getter|2|154-postInit
            // write post-init user code here
        }//GEN-BEGIN:|154-getter|3|
        return alertaOn;
    }
//</editor-fold>//GEN-END:|154-getter|3|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: okSendSMS ">//GEN-BEGIN:|155-getter|0|155-preInit
    /**
     * Returns an initiliazed instance of okSendSMS component.
     * @return the initialized component instance
     */
    public Command getOkSendSMS() {
        if (okSendSMS == null) {//GEN-END:|155-getter|0|155-preInit
            // write pre-init user code here
            okSendSMS = new Command("Ok", Command.OK, 0);//GEN-LINE:|155-getter|1|155-postInit
            // write post-init user code here
        }//GEN-BEGIN:|155-getter|2|
        return okSendSMS;
    }
//</editor-fold>//GEN-END:|155-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: spacer1 ">//GEN-BEGIN:|157-getter|0|157-preInit
    /**
     * Returns an initiliazed instance of spacer1 component.
     * @return the initialized component instance
     */
    public Spacer getSpacer1() {
        if (spacer1 == null) {//GEN-END:|157-getter|0|157-preInit
            // write pre-init user code here
            spacer1 = new Spacer(16, 15);//GEN-LINE:|157-getter|1|157-postInit
            // write post-init user code here
        }//GEN-BEGIN:|157-getter|2|
        return spacer1;
    }
//</editor-fold>//GEN-END:|157-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: spacer2 ">//GEN-BEGIN:|158-getter|0|158-preInit
    /**
     * Returns an initiliazed instance of spacer2 component.
     * @return the initialized component instance
     */
    public Spacer getSpacer2() {
        if (spacer2 == null) {//GEN-END:|158-getter|0|158-preInit
            // write pre-init user code here
            spacer2 = new Spacer(16, 10);//GEN-LINE:|158-getter|1|158-postInit
            // write post-init user code here
        }//GEN-BEGIN:|158-getter|2|
        return spacer2;
    }
//</editor-fold>//GEN-END:|158-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem6 ">//GEN-BEGIN:|159-getter|0|159-preInit
    /**
     * Returns an initiliazed instance of imageItem6 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem6() {
        if (imageItem6 == null) {//GEN-END:|159-getter|0|159-preInit
            // write pre-init user code here
            imageItem6 = new ImageItem("", this.newAlert ? getAlertaOn() : getAlertaOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|159-getter|1|159-postInit
            imageItem6.addCommand(getGoToAlerts());
            imageItem6.setItemCommandListener(this);
            imageItem6.setDefaultCommand(getGoToAlerts());//GEN-END:|159-getter|1|159-postInit
            // write post-init user code here
        }//GEN-BEGIN:|159-getter|2|
        return imageItem6;
    }
//</editor-fold>//GEN-END:|159-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: spacer3 ">//GEN-BEGIN:|162-getter|0|162-preInit
    /**
     * Returns an initiliazed instance of spacer3 component.
     * @return the initialized component instance
     */
    public Spacer getSpacer3() {
        if (spacer3 == null) {//GEN-END:|162-getter|0|162-preInit
            // write pre-init user code here
            spacer3 = new Spacer(16, 10);//GEN-BEGIN:|162-getter|1|162-postInit
            spacer3.setLayout(ImageItem.LAYOUT_DEFAULT | ImageItem.LAYOUT_NEWLINE_BEFORE | ImageItem.LAYOUT_NEWLINE_AFTER);//GEN-END:|162-getter|1|162-postInit
            // write post-init user code here
        }//GEN-BEGIN:|162-getter|2|
        return spacer3;
    }
//</editor-fold>//GEN-END:|162-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem7 ">//GEN-BEGIN:|163-getter|0|163-preInit
    /**
     * Returns an initiliazed instance of imageItem7 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem7() {
        if (imageItem7 == null) {//GEN-END:|163-getter|0|163-preInit
            // write pre-init user code here
            imageItem7 = new ImageItem("", receiveSMS.isNewAlert() ? getMensagemOn() : getMensagemOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|163-getter|1|163-postInit
            imageItem7.addCommand(getGoToMessages());
            imageItem7.setItemCommandListener(this);
            imageItem7.setDefaultCommand(getGoToMessages());//GEN-END:|163-getter|1|163-postInit
            // write post-init user code here
        }//GEN-BEGIN:|163-getter|2|
        return imageItem7;
    }
//</editor-fold>//GEN-END:|163-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Method: verificaLogin ">//GEN-BEGIN:|166-if|0|166-preIf
    /**
     * Performs an action assigned to the verificaLogin if-point.
     */
    public void verificaLogin() {//GEN-END:|166-if|0|166-preIf
        // enter pre-if user code here
        if (this.logged) {//GEN-LINE:|166-if|1|167-preAction
            switchDisplayable(null, getMainMenu());//GEN-LINE:|166-if|2|167-postAction
            // write post-action user code here
        } else {//GEN-LINE:|166-if|3|168-preAction

            switchDisplayable(null, getLogin());//GEN-LINE:|166-if|4|168-postAction
            // write post-action user code here
        }//GEN-LINE:|166-if|5|166-postIf
        // enter post-if user code here
    }//GEN-BEGIN:|166-if|6|
//</editor-fold>//GEN-END:|166-if|6|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: screenCommand1 ">//GEN-BEGIN:|164-getter|0|164-preInit
    /**
     * Returns an initiliazed instance of screenCommand1 component.
     * @return the initialized component instance
     */
    public Command getScreenCommand1() {
        if (screenCommand1 == null) {//GEN-END:|164-getter|0|164-preInit
            // write pre-init user code here
            screenCommand1 = new Command("Screen", Command.SCREEN, 0);//GEN-LINE:|164-getter|1|164-postInit
            // write post-init user code here
        }//GEN-BEGIN:|164-getter|2|
        return screenCommand1;
    }
//</editor-fold>//GEN-END:|164-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem8 ">//GEN-BEGIN:|173-getter|0|173-preInit
    /**
     * Returns an initiliazed instance of imageItem8 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem8() {
        if (imageItem8 == null) {//GEN-END:|173-getter|0|173-preInit
            // write pre-init user code here
            imageItem8 = new ImageItem("", this.newAlert ? getAlertaOn() : getAlertaOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|173-getter|1|173-postInit
            imageItem8.addCommand(getGoToAlerts());
            imageItem8.setItemCommandListener(this);
            imageItem8.setDefaultCommand(getGoToAlerts());//GEN-END:|173-getter|1|173-postInit
            // write post-init user code here
        }//GEN-BEGIN:|173-getter|2|
        return imageItem8;
    }
//</editor-fold>//GEN-END:|173-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem9 ">//GEN-BEGIN:|175-getter|0|175-preInit
    /**
     * Returns an initiliazed instance of imageItem9 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem9() {
        if (imageItem9 == null) {//GEN-END:|175-getter|0|175-preInit
            // write pre-init user code here
            imageItem9 = new ImageItem("", receiveSMS.isNewAlert() ? getMensagemOn() : getMensagemOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|175-getter|1|175-postInit
            imageItem9.addCommand(getGoToMessages());
            imageItem9.setItemCommandListener(this);
            imageItem9.setDefaultCommand(getGoToMessages());//GEN-END:|175-getter|1|175-postInit
            // write post-init user code here
        }//GEN-BEGIN:|175-getter|2|
        return imageItem9;
    }
//</editor-fold>//GEN-END:|175-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: spacer4 ">//GEN-BEGIN:|176-getter|0|176-preInit
    /**
     * Returns an initiliazed instance of spacer4 component.
     * @return the initialized component instance
     */
    public Spacer getSpacer4() {
        if (spacer4 == null) {//GEN-END:|176-getter|0|176-preInit
            // write pre-init user code here
            spacer4 = new Spacer(16, 10);//GEN-LINE:|176-getter|1|176-postInit
            // write post-init user code here
        }//GEN-BEGIN:|176-getter|2|
        return spacer4;
    }
//</editor-fold>//GEN-END:|176-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem10 ">//GEN-BEGIN:|178-getter|0|178-preInit
    /**
     * Returns an initiliazed instance of imageItem10 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem10() {
        if (imageItem10 == null) {//GEN-END:|178-getter|0|178-preInit
            // write pre-init user code here
            imageItem10 = new ImageItem("", this.newAlert ? getAlertaOn() : getAlertaOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-LINE:|178-getter|1|178-postInit
            // write post-init user code here
        }//GEN-BEGIN:|178-getter|2|
        return imageItem10;
    }
//</editor-fold>//GEN-END:|178-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem11 ">//GEN-BEGIN:|179-getter|0|179-preInit
    /**
     * Returns an initiliazed instance of imageItem11 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem11() {
        if (imageItem11 == null) {//GEN-END:|179-getter|0|179-preInit
            // write pre-init user code here
            imageItem11 = new ImageItem("", receiveSMS.isNewAlert() ? getMensagemOn() : getMensagemOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|179-getter|1|179-postInit
            imageItem11.addCommand(getGoToMessages());
            imageItem11.setItemCommandListener(this);
            imageItem11.setDefaultCommand(getGoToMessages());//GEN-END:|179-getter|1|179-postInit
            // write post-init user code here
        }//GEN-BEGIN:|179-getter|2|
        return imageItem11;
    }
//</editor-fold>//GEN-END:|179-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: spacer5 ">//GEN-BEGIN:|180-getter|0|180-preInit
    /**
     * Returns an initiliazed instance of spacer5 component.
     * @return the initialized component instance
     */
    public Spacer getSpacer5() {
        if (spacer5 == null) {//GEN-END:|180-getter|0|180-preInit
            // write pre-init user code here
            spacer5 = new Spacer(16, 10);//GEN-BEGIN:|180-getter|1|180-postInit
            spacer5.setLayout(ImageItem.LAYOUT_DEFAULT | ImageItem.LAYOUT_NEWLINE_BEFORE | ImageItem.LAYOUT_NEWLINE_AFTER);//GEN-END:|180-getter|1|180-postInit
            // write post-init user code here
        }//GEN-BEGIN:|180-getter|2|
        return spacer5;
    }
//</editor-fold>//GEN-END:|180-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem12 ">//GEN-BEGIN:|182-getter|0|182-preInit
    /**
     * Returns an initiliazed instance of imageItem12 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem12() {
        if (imageItem12 == null) {//GEN-END:|182-getter|0|182-preInit
            // write pre-init user code here
            imageItem12 = new ImageItem("", this.newAlert ? getAlertaOn() : getAlertaOff(), ImageItem.LAYOUT_DEFAULT, "<Missing Image>");//GEN-BEGIN:|182-getter|1|182-postInit
            imageItem12.addCommand(getGoToAlerts());
            imageItem12.setItemCommandListener(this);
            imageItem12.setDefaultCommand(getGoToAlerts());//GEN-END:|182-getter|1|182-postInit
            // write post-init user code here
        }//GEN-BEGIN:|182-getter|2|
        return imageItem12;
    }
//</editor-fold>//GEN-END:|182-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem13 ">//GEN-BEGIN:|183-getter|0|183-preInit
    /**
     * Returns an initiliazed instance of imageItem13 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem13() {
        if (imageItem13 == null) {//GEN-END:|183-getter|0|183-preInit
            // write pre-init user code here
            imageItem13 = new ImageItem("", receiveSMS.isNewAlert() ? getMensagemOn() : getMensagemOff(), ImageItem.LAYOUT_DEFAULT, "<Missing Image>");//GEN-BEGIN:|183-getter|1|183-postInit
            imageItem13.addCommand(getGoToMessages());
            imageItem13.setItemCommandListener(this);
            imageItem13.setDefaultCommand(getGoToMessages());//GEN-END:|183-getter|1|183-postInit
            // write post-init user code here
        }//GEN-BEGIN:|183-getter|2|
        return imageItem13;
    }
//</editor-fold>//GEN-END:|183-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: spacer6 ">//GEN-BEGIN:|184-getter|0|184-preInit
    /**
     * Returns an initiliazed instance of spacer6 component.
     * @return the initialized component instance
     */
    public Spacer getSpacer6() {
        if (spacer6 == null) {//GEN-END:|184-getter|0|184-preInit
            // write pre-init user code here
            spacer6 = new Spacer(16, 10);//GEN-LINE:|184-getter|1|184-postInit
            // write post-init user code here
        }//GEN-BEGIN:|184-getter|2|
        return spacer6;
    }
//</editor-fold>//GEN-END:|184-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem14 ">//GEN-BEGIN:|187-getter|0|187-preInit
    /**
     * Returns an initiliazed instance of imageItem14 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem14() {
        if (imageItem14 == null) {//GEN-END:|187-getter|0|187-preInit
            // write pre-init user code here
            imageItem14 = new ImageItem("", this.newAlert ? getAlertaOn() : getAlertaOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|187-getter|1|187-postInit
            imageItem14.addCommand(getGoToAlerts());
            imageItem14.setItemCommandListener(this);
            imageItem14.setDefaultCommand(getGoToAlerts());//GEN-END:|187-getter|1|187-postInit
            // write post-init user code here
        }//GEN-BEGIN:|187-getter|2|
        return imageItem14;
    }
//</editor-fold>//GEN-END:|187-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem15 ">//GEN-BEGIN:|188-getter|0|188-preInit
    /**
     * Returns an initiliazed instance of imageItem15 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem15() {
        if (imageItem15 == null) {//GEN-END:|188-getter|0|188-preInit
            // write pre-init user code here
            imageItem15 = new ImageItem("", receiveSMS.isNewAlert() ? getMensagemOn() : getMensagemOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|188-getter|1|188-postInit
            imageItem15.addCommand(getGoToMessages());
            imageItem15.setItemCommandListener(this);
            imageItem15.setDefaultCommand(getGoToMessages());//GEN-END:|188-getter|1|188-postInit
            // write post-init user code here
        }//GEN-BEGIN:|188-getter|2|
        return imageItem15;
    }
//</editor-fold>//GEN-END:|188-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: spacer7 ">//GEN-BEGIN:|189-getter|0|189-preInit
    /**
     * Returns an initiliazed instance of spacer7 component.
     * @return the initialized component instance
     */
    public Spacer getSpacer7() {
        if (spacer7 == null) {//GEN-END:|189-getter|0|189-preInit
            // write pre-init user code here
            spacer7 = new Spacer(16, 10);//GEN-LINE:|189-getter|1|189-postInit
            // write post-init user code here
        }//GEN-BEGIN:|189-getter|2|
        return spacer7;
    }
//</editor-fold>//GEN-END:|189-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem16 ">//GEN-BEGIN:|192-getter|0|192-preInit
    /**
     * Returns an initiliazed instance of imageItem16 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem16() {
        if (imageItem16 == null) {//GEN-END:|192-getter|0|192-preInit
            // write pre-init user code here
            imageItem16 = new ImageItem("", this.newAlert ? getAlertaOn() : getAlertaOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|192-getter|1|192-postInit
            imageItem16.addCommand(getGoToAlerts());
            imageItem16.setItemCommandListener(this);
            imageItem16.setDefaultCommand(getGoToAlerts());//GEN-END:|192-getter|1|192-postInit
            // write post-init user code here
        }//GEN-BEGIN:|192-getter|2|
        return imageItem16;
    }
//</editor-fold>//GEN-END:|192-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem17 ">//GEN-BEGIN:|193-getter|0|193-preInit
    /**
     * Returns an initiliazed instance of imageItem17 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem17() {
        if (imageItem17 == null) {//GEN-END:|193-getter|0|193-preInit
            // write pre-init user code here
            imageItem17 = new ImageItem("", receiveSMS.isNewAlert() ? getMensagemOn() : getMensagemOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|193-getter|1|193-postInit
            imageItem17.addCommand(getGoToMessages());
            imageItem17.setItemCommandListener(this);
            imageItem17.setDefaultCommand(getGoToMessages());//GEN-END:|193-getter|1|193-postInit
            // write post-init user code here
        }//GEN-BEGIN:|193-getter|2|
        return imageItem17;
    }
//</editor-fold>//GEN-END:|193-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: spacer8 ">//GEN-BEGIN:|194-getter|0|194-preInit
    /**
     * Returns an initiliazed instance of spacer8 component.
     * @return the initialized component instance
     */
    public Spacer getSpacer8() {
        if (spacer8 == null) {//GEN-END:|194-getter|0|194-preInit
            // write pre-init user code here
            spacer8 = new Spacer(16, 10);//GEN-BEGIN:|194-getter|1|194-postInit
            spacer8.setLayout(ImageItem.LAYOUT_DEFAULT | ImageItem.LAYOUT_NEWLINE_BEFORE | ImageItem.LAYOUT_NEWLINE_AFTER);//GEN-END:|194-getter|1|194-postInit
            // write post-init user code here
        }//GEN-BEGIN:|194-getter|2|
        return spacer8;
    }
//</editor-fold>//GEN-END:|194-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem18 ">//GEN-BEGIN:|197-getter|0|197-preInit
    /**
     * Returns an initiliazed instance of imageItem18 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem18() {
        if (imageItem18 == null) {//GEN-END:|197-getter|0|197-preInit
            // write pre-init user code here
            imageItem18 = new ImageItem("", this.newAlert ? getAlertaOn() : getAlertaOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|197-getter|1|197-postInit
            imageItem18.addCommand(getGoToAlerts());
            imageItem18.setItemCommandListener(this);
            imageItem18.setDefaultCommand(getGoToAlerts());//GEN-END:|197-getter|1|197-postInit
            // write post-init user code here
        }//GEN-BEGIN:|197-getter|2|
        return imageItem18;
    }
//</editor-fold>//GEN-END:|197-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem19 ">//GEN-BEGIN:|198-getter|0|198-preInit
    /**
     * Returns an initiliazed instance of imageItem19 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem19() {
        if (imageItem19 == null) {//GEN-END:|198-getter|0|198-preInit
            // write pre-init user code here
            imageItem19 = new ImageItem("", receiveSMS.isNewAlert() ? getMensagemOn() : getMensagemOff(), ImageItem.LAYOUT_DEFAULT, "<Missing Image>");//GEN-BEGIN:|198-getter|1|198-postInit
            imageItem19.addCommand(getGoToMessages());
            imageItem19.setItemCommandListener(this);
            imageItem19.setDefaultCommand(getGoToMessages());//GEN-END:|198-getter|1|198-postInit
            // write post-init user code here
        }//GEN-BEGIN:|198-getter|2|
        return imageItem19;
    }
//</editor-fold>//GEN-END:|198-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: spacer9 ">//GEN-BEGIN:|199-getter|0|199-preInit
    /**
     * Returns an initiliazed instance of spacer9 component.
     * @return the initialized component instance
     */
    public Spacer getSpacer9() {
        if (spacer9 == null) {//GEN-END:|199-getter|0|199-preInit
            // write pre-init user code here
            spacer9 = new Spacer(16, 10);//GEN-LINE:|199-getter|1|199-postInit
            // write post-init user code here
        }//GEN-BEGIN:|199-getter|2|
        return spacer9;
    }
//</editor-fold>//GEN-END:|199-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: dayFont ">//GEN-BEGIN:|203-getter|0|203-preInit
    /**
     * Returns an initiliazed instance of dayFont component.
     * @return the initialized component instance
     */
    public Font getDayFont() {
        if (dayFont == null) {//GEN-END:|203-getter|0|203-preInit
            // write pre-init user code here
            dayFont = Font.getFont(Font.FACE_MONOSPACE, Font.STYLE_BOLD, Font.SIZE_LARGE);//GEN-LINE:|203-getter|1|203-postInit
            // write post-init user code here
        }//GEN-BEGIN:|203-getter|2|
        return dayFont;
    }
//</editor-fold>//GEN-END:|203-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: messages ">//GEN-BEGIN:|204-getter|0|204-preInit
    /**
     * Returns an initiliazed instance of messages component.
     * @return the initialized component instance
     */
    public Form getMessages() {
        if (messages == null) {//GEN-END:|204-getter|0|204-preInit
            // write pre-init user code here
            messages = new Form("Mensagens", new Item[]{getImageItem20(), getImageItem21(), getSpacer10(), getInbox(), getImageItem22()});//GEN-BEGIN:|204-getter|1|204-postInit
            messages.addCommand(getBackCommand());
            messages.setCommandListener(this);//GEN-END:|204-getter|1|204-postInit
            // write post-init user code here
        }//GEN-BEGIN:|204-getter|2|
        return messages;
    }
//</editor-fold>//GEN-END:|204-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToInbox ">//GEN-BEGIN:|210-getter|0|210-preInit
    /**
     * Returns an initiliazed instance of goToInbox component.
     * @return the initialized component instance
     */
    public Command getGoToInbox() {
        if (goToInbox == null) {//GEN-END:|210-getter|0|210-preInit
            // write pre-init user code here
            goToInbox = new Command("Confirmar", Command.SCREEN, 0);//GEN-LINE:|210-getter|1|210-postInit
            // write post-init user code here
        }//GEN-BEGIN:|210-getter|2|
        return goToInbox;
    }
//</editor-fold>//GEN-END:|210-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToSendSMS ">//GEN-BEGIN:|212-getter|0|212-preInit
    /**
     * Returns an initiliazed instance of goToSendSMS component.
     * @return the initialized component instance
     */
    public Command getGoToSendSMS() {
        if (goToSendSMS == null) {//GEN-END:|212-getter|0|212-preInit
            // write pre-init user code here
            goToSendSMS = new Command("Confirmar", Command.SCREEN, 0);//GEN-LINE:|212-getter|1|212-postInit
            // write post-init user code here
        }//GEN-BEGIN:|212-getter|2|
        return goToSendSMS;
    }
//</editor-fold>//GEN-END:|212-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem20 ">//GEN-BEGIN:|205-getter|0|205-preInit
    /**
     * Returns an initiliazed instance of imageItem20 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem20() {
        if (imageItem20 == null) {//GEN-END:|205-getter|0|205-preInit
            // write pre-init user code here
            imageItem20 = new ImageItem("", this.newAlert ? getAlertaOn() : getAlertaOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|205-getter|1|205-postInit
            imageItem20.addCommand(getGoToAlerts());
            imageItem20.setItemCommandListener(this);
            imageItem20.setDefaultCommand(getGoToAlerts());//GEN-END:|205-getter|1|205-postInit
            // write post-init user code here
        }//GEN-BEGIN:|205-getter|2|
        return imageItem20;
    }
//</editor-fold>//GEN-END:|205-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem21 ">//GEN-BEGIN:|206-getter|0|206-preInit
    /**
     * Returns an initiliazed instance of imageItem21 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem21() {
        if (imageItem21 == null) {//GEN-END:|206-getter|0|206-preInit
            // write pre-init user code here
            imageItem21 = new ImageItem("", receiveSMS.isNewAlert() ? getMensagemOn() : getMensagemOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|206-getter|1|206-postInit
            imageItem21.addCommand(getGoToMessages());
            imageItem21.setItemCommandListener(this);
            imageItem21.setDefaultCommand(getGoToMessages());//GEN-END:|206-getter|1|206-postInit
            // write post-init user code here
        }//GEN-BEGIN:|206-getter|2|
        return imageItem21;
    }
//</editor-fold>//GEN-END:|206-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: spacer10 ">//GEN-BEGIN:|207-getter|0|207-preInit
    /**
     * Returns an initiliazed instance of spacer10 component.
     * @return the initialized component instance
     */
    public Spacer getSpacer10() {
        if (spacer10 == null) {//GEN-END:|207-getter|0|207-preInit
            // write pre-init user code here
            spacer10 = new Spacer(16, 1);//GEN-LINE:|207-getter|1|207-postInit
            // write post-init user code here
        }//GEN-BEGIN:|207-getter|2|
        return spacer10;
    }
//</editor-fold>//GEN-END:|207-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: inbox ">//GEN-BEGIN:|208-getter|0|208-preInit
    /**
     * Returns an initiliazed instance of inbox component.
     * @return the initialized component instance
     */
    public ImageItem getInbox() {
        if (inbox == null) {//GEN-END:|208-getter|0|208-preInit
            // write pre-init user code here
            inbox = new ImageItem("Caixa de entrada", getInboxSMSImg(), ImageItem.LAYOUT_CENTER | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|208-getter|1|208-postInit
            inbox.addCommand(getGoToInbox());
            inbox.setItemCommandListener(this);
            inbox.setDefaultCommand(getGoToInbox());//GEN-END:|208-getter|1|208-postInit
            // write post-init user code here
        }//GEN-BEGIN:|208-getter|2|
        return inbox;
    }
//</editor-fold>//GEN-END:|208-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem22 ">//GEN-BEGIN:|209-getter|0|209-preInit
    /**
     * Returns an initiliazed instance of imageItem22 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem22() {
        if (imageItem22 == null) {//GEN-END:|209-getter|0|209-preInit
            // write pre-init user code here
            imageItem22 = new ImageItem("Enviar", getSendSMSImg(), ImageItem.LAYOUT_CENTER | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|209-getter|1|209-postInit
            imageItem22.addCommand(getGoToSendSMS());
            imageItem22.setItemCommandListener(this);
            imageItem22.setDefaultCommand(getGoToSendSMS());//GEN-END:|209-getter|1|209-postInit
            // write post-init user code here
        }//GEN-BEGIN:|209-getter|2|
        return imageItem22;
    }
//</editor-fold>//GEN-END:|209-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToInbox1 ">//GEN-BEGIN:|225-getter|0|225-preInit
    /**
     * Returns an initiliazed instance of goToInbox1 component.
     * @return the initialized component instance
     */
    public Command getGoToInbox1() {
        if (goToInbox1 == null) {//GEN-END:|225-getter|0|225-preInit
            // write pre-init user code here
            goToInbox1 = new Command("Confirmar", Command.SCREEN, 0);//GEN-LINE:|225-getter|1|225-postInit
            // write post-init user code here
        }//GEN-BEGIN:|225-getter|2|
        return goToInbox1;
    }
//</editor-fold>//GEN-END:|225-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToSendSMS1 ">//GEN-BEGIN:|229-getter|0|229-preInit
    /**
     * Returns an initiliazed instance of goToSendSMS1 component.
     * @return the initialized component instance
     */
    public Command getGoToSendSMS1() {
        if (goToSendSMS1 == null) {//GEN-END:|229-getter|0|229-preInit
            // write pre-init user code here
            goToSendSMS1 = new Command("Screen", Command.SCREEN, 0);//GEN-LINE:|229-getter|1|229-postInit
            // write post-init user code here
        }//GEN-BEGIN:|229-getter|2|
        return goToSendSMS1;
    }
//</editor-fold>//GEN-END:|229-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: inboxScreen ">//GEN-BEGIN:|234-getter|0|234-preInit
    /**
     * Returns an initiliazed instance of inboxScreen component.
     * @return the initialized component instance
     */
    public Form getInboxScreen() {
        if (inboxScreen == null) {//GEN-END:|234-getter|0|234-preInit
            // write pre-init user code here
            inboxScreen = new Form("Caixa de entrada", new Item[]{getImageItem23(), getImageItem24(), getSpacer11(), getInboxList()});//GEN-BEGIN:|234-getter|1|234-postInit
            inboxScreen.addCommand(getBackInbox());
            inboxScreen.setCommandListener(this);//GEN-END:|234-getter|1|234-postInit
            // write post-init user code here
        }//GEN-BEGIN:|234-getter|2|
        return inboxScreen;
    }
//</editor-fold>//GEN-END:|234-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem23 ">//GEN-BEGIN:|235-getter|0|235-preInit
    /**
     * Returns an initiliazed instance of imageItem23 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem23() {
        if (imageItem23 == null) {//GEN-END:|235-getter|0|235-preInit
            // write pre-init user code here
            imageItem23 = new ImageItem("", this.newAlert ? getAlertaOn() : getAlertaOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_BOTTOM | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|235-getter|1|235-postInit
            imageItem23.addCommand(getGoToAlerts());
            imageItem23.setItemCommandListener(this);
            imageItem23.setDefaultCommand(getGoToAlerts());//GEN-END:|235-getter|1|235-postInit
            // write post-init user code here
        }//GEN-BEGIN:|235-getter|2|
        return imageItem23;
    }
//</editor-fold>//GEN-END:|235-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: imageItem24 ">//GEN-BEGIN:|236-getter|0|236-preInit
    /**
     * Returns an initiliazed instance of imageItem24 component.
     * @return the initialized component instance
     */
    public ImageItem getImageItem24() {
        if (imageItem24 == null) {//GEN-END:|236-getter|0|236-preInit
            // write pre-init user code here
            imageItem24 = new ImageItem("", receiveSMS.isNewAlert() ? getMensagemOn() : getMensagemOff(), ImageItem.LAYOUT_DEFAULT | Item.LAYOUT_TOP | Item.LAYOUT_VCENTER, "<Missing Image>");//GEN-BEGIN:|236-getter|1|236-postInit
            imageItem24.addCommand(getGoToMessages());
            imageItem24.setItemCommandListener(this);
            imageItem24.setDefaultCommand(getGoToMessages());//GEN-END:|236-getter|1|236-postInit
            // write post-init user code here
        }//GEN-BEGIN:|236-getter|2|
        return imageItem24;
    }
//</editor-fold>//GEN-END:|236-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: spacer11 ">//GEN-BEGIN:|237-getter|0|237-preInit
    /**
     * Returns an initiliazed instance of spacer11 component.
     * @return the initialized component instance
     */
    public Spacer getSpacer11() {
        if (spacer11 == null) {//GEN-END:|237-getter|0|237-preInit
            // write pre-init user code here
            spacer11 = new Spacer(16, 1);//GEN-LINE:|237-getter|1|237-postInit
            // write post-init user code here
        }//GEN-BEGIN:|237-getter|2|
        return spacer11;
    }
//</editor-fold>//GEN-END:|237-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: inboxList ">//GEN-BEGIN:|242-getter|0|242-preInit
    /**
     * Returns an initiliazed instance of inboxList component.
     * @return the initialized component instance
     */
    public StringItem getInboxList() {
        if (inboxList == null) {//GEN-END:|242-getter|0|242-preInit
            // write pre-init user code here
            inboxList = new StringItem("", null);//GEN-BEGIN:|242-getter|1|242-postInit
            inboxList.setFont(getDayFont());//GEN-END:|242-getter|1|242-postInit
            String output = "";
            Vector aux = receiveSMS.getMensagens();
            System.out.println("\t\tputa: " + receiveSMS.getPuta());
            for (int i = aux.size() - 1; i >= 0; i--) {
                output += aux.elementAt(i)
                        + "\n----------\n";
            }
            System.out.println("\t\ti: " + aux.size());
            System.out.println("\t\t" + output);
            inboxList.setText("\t\t" + output);
            //inboxList.setText("");
        }//GEN-BEGIN:|242-getter|2|
        return inboxList;
    }
//</editor-fold>//GEN-END:|242-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: goToInbox2 ">//GEN-BEGIN:|245-getter|0|245-preInit
    /**
     * Returns an initiliazed instance of goToInbox2 component.
     * @return the initialized component instance
     */
    public Command getGoToInbox2() {
        if (goToInbox2 == null) {//GEN-END:|245-getter|0|245-preInit
            // write pre-init user code here
            goToInbox2 = new Command("Screen", Command.SCREEN, 0);//GEN-LINE:|245-getter|1|245-postInit
            // write post-init user code here
        }//GEN-BEGIN:|245-getter|2|
        return goToInbox2;
    }
//</editor-fold>//GEN-END:|245-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: backInbox ">//GEN-BEGIN:|251-getter|0|251-preInit
    /**
     * Returns an initiliazed instance of backInbox component.
     * @return the initialized component instance
     */
    public Command getBackInbox() {
        if (backInbox == null) {//GEN-END:|251-getter|0|251-preInit
            // write pre-init user code here
            backInbox = new Command("Voltar", Command.BACK, 0);//GEN-LINE:|251-getter|1|251-postInit
            // write post-init user code here
        }//GEN-BEGIN:|251-getter|2|
        return backInbox;
    }
//</editor-fold>//GEN-END:|251-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: backMessages ">//GEN-BEGIN:|253-getter|0|253-preInit
    /**
     * Returns an initiliazed instance of backMessages component.
     * @return the initialized component instance
     */
    public Command getBackMessages() {
        if (backMessages == null) {//GEN-END:|253-getter|0|253-preInit
            // write pre-init user code here
            backMessages = new Command("Back", Command.BACK, 0);//GEN-LINE:|253-getter|1|253-postInit
            // write post-init user code here
        }//GEN-BEGIN:|253-getter|2|
        return backMessages;
    }
//</editor-fold>//GEN-END:|253-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: backCommand ">//GEN-BEGIN:|255-getter|0|255-preInit
    /**
     * Returns an initiliazed instance of backCommand component.
     * @return the initialized component instance
     */
    public Command getBackCommand() {
        if (backCommand == null) {//GEN-END:|255-getter|0|255-preInit
            // write pre-init user code here
            backCommand = new Command("Voltar", Command.BACK, 0);//GEN-LINE:|255-getter|1|255-postInit
            // write post-init user code here
        }//GEN-BEGIN:|255-getter|2|
        return backCommand;
    }
//</editor-fold>//GEN-END:|255-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: alertText ">//GEN-BEGIN:|259-getter|0|259-preInit
    /**
     * Returns an initiliazed instance of alertText component.
     * @return the initialized component instance
     */
    public StringItem getAlertText() {
        if (alertText == null) {//GEN-END:|259-getter|0|259-preInit
            // write pre-init user code here
            alertText = new StringItem("", this.newAlert ? "Foi disponibilizado novo material no inforestudante" : "Não tem novos alertas");//GEN-BEGIN:|259-getter|1|259-postInit
            alertText.setFont(getDayFont());//GEN-END:|259-getter|1|259-postInit
            // write post-init user code here
        }//GEN-BEGIN:|259-getter|2|
        return alertText;
    }
//</editor-fold>//GEN-END:|259-getter|2|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: inboxSMSImg ">//GEN-BEGIN:|261-getter|0|261-preInit
    /**
     * Returns an initiliazed instance of inboxSMSImg component.
     * @return the initialized component instance
     */
    public Image getInboxSMSImg() {
        if (inboxSMSImg == null) {//GEN-END:|261-getter|0|261-preInit
            // write pre-init user code here
            try {//GEN-BEGIN:|261-getter|1|261-@java.io.IOException
                inboxSMSImg = Image.createImage("/images/mensagem_recebidas.png");
            } catch (java.io.IOException e) {//GEN-END:|261-getter|1|261-@java.io.IOException
                e.printStackTrace();
            }//GEN-LINE:|261-getter|2|261-postInit
            // write post-init user code here
        }//GEN-BEGIN:|261-getter|3|
        return inboxSMSImg;
    }
//</editor-fold>//GEN-END:|261-getter|3|

//<editor-fold defaultstate="collapsed" desc=" Generated Getter: sendSMSImg ">//GEN-BEGIN:|262-getter|0|262-preInit
    /**
     * Returns an initiliazed instance of sendSMSImg component.
     * @return the initialized component instance
     */
    public Image getSendSMSImg() {
        if (sendSMSImg == null) {//GEN-END:|262-getter|0|262-preInit
            // write pre-init user code here
            try {//GEN-BEGIN:|262-getter|1|262-@java.io.IOException
                sendSMSImg = Image.createImage("/images/mensagem_enviar.png");
            } catch (java.io.IOException e) {//GEN-END:|262-getter|1|262-@java.io.IOException
                e.printStackTrace();
            }//GEN-LINE:|262-getter|2|262-postInit
            // write post-init user code here
        }//GEN-BEGIN:|262-getter|3|
        return sendSMSImg;
    }
//</editor-fold>//GEN-END:|262-getter|3|

    /**
     * Returns a display instance.
     * @return the display instance.
     */
    public Display getDisplay() {
        return Display.getDisplay(this);
    }

    /**
     * Exits MIDlet.
     */
    public void exitMIDlet() {
        switchDisplayable(null, null);
        destroyApp(true);
        notifyDestroyed();
    }

    /**
     * Called when MIDlet is started.
     * Checks whether the MIDlet have been already started and initialize/starts or resumes the MIDlet.
     */
    public void startApp() {
        if (midletPaused) {
            resumeMIDlet();
        } else {
            initialize();
            startMIDlet();
        }
        midletPaused = false;
    }

    /**
     * Called when MIDlet is paused.
     */
    public void pauseApp() {
        midletPaused = true;
    }

    /**
     * Called to signal the MIDlet to terminate.
     * @param unconditional if true, then the MIDlet has to be unconditionally terminated and all resources has to be released.
     */
    public void destroyApp(boolean unconditional) {
    }

    private String[] split(String original, String separator) {
        Vector nodes = new Vector();
        // Parse nodes into vector
        int index = original.indexOf(separator);
        while (index >= 0) {
            nodes.addElement(original.substring(0, index));
            original = original.substring(index + separator.length());
            index = original.indexOf(separator);
        }
        // Get the last node
        nodes.addElement(original);

        // Create split string array
        String[] result = new String[nodes.size()];
        if (nodes.size() > 0) {
            for (int loop = 0; loop < nodes.size(); loop++) {
                result[loop] = (String) nodes.elementAt(loop);
                //System.out.println(result[loop]);
            }

        }
        return result;
    }

    public void clearIcons() {

        ImageItem[] imagens = {imageItem, imageItem1, imageItem10, imageItem11, imageItem6, imageItem7,
            imageItem13, imageItem12, imageItem14, imageItem15, imageItem16, imageItem17, imageItem18, imageItem19,
            imageItem20, imageItem21, imageItem22, imageItem23};

        for (int i = 0; i < imagens.length; i++) {
            imagens[i] = null;
        }
    }
}
